Date: Mon, 12 Nov 2012 08:11:50 GMT From: Robert Watson <rwatson@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 219760 for review Message-ID: <201211120811.qAC8BobV055225@skunkworks.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://p4web.freebsd.org/@@219760?ac=10 Change 219760 by rwatson@rwatson_zenith_cl_cam_ac_uk on 2012/11/12 08:11:12 Initialise $gp in cheritest-helper, which means we no longer have to compile with -G0 (I hope). This should (may) allow us to link sandboxed components against libraries. Affected files ... .. //depot/projects/ctsrd/cheribsd/src/libexec/cheritest-helper/Makefile#4 edit .. //depot/projects/ctsrd/cheribsd/src/libexec/cheritest-helper/mips64/chsbrt.S#2 edit .. //depot/projects/ctsrd/cheribsd/src/libexec/cheritest-helper/sandbox.ld#3 edit Differences ... ==== //depot/projects/ctsrd/cheribsd/src/libexec/cheritest-helper/Makefile#4 (text+ko) ==== @@ -4,7 +4,6 @@ PROG= cheritest-helper SRCS= cheritest-helper.c chsbrt.S LDFLAGS+= -Wl,--script=${.CURDIR}/sandbox.ld -nostdlib -CFLAGS+= -G0 -Wa,-G0 NO_MAN= #STRIP= NO_SHARED= yes ==== //depot/projects/ctsrd/cheribsd/src/libexec/cheritest-helper/mips64/chsbrt.S#2 (text+ko) ==== @@ -121,10 +121,7 @@ # registers that aren't explicit or ABI-implied arguments. # - # - # XXXRW: Initialise $gp? - # - dla $gp, 0 + dla $gp, _gp # # Invoke MIPS ABI C "invoke" function. ==== //depot/projects/ctsrd/cheribsd/src/libexec/cheritest-helper/sandbox.ld#3 (text+ko) ==== @@ -47,6 +47,9 @@ .bss ALIGN(0x8): { *(.bss) } .data ALIGN(0x8): { *(.data) } + _gp = ALIGN(16) + 0x7ff0; + .got : { *(.got.plt) *(.got) } + /* * Force zero-filling of previous segments in generated image. */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201211120811.qAC8BobV055225>