Re: [Gems-users] Compiling problems with transaction.c in Gems 2.0


Date: Wed, 10 Oct 2007 10:21:12 +0200
From: "Rubén Titos" <rtitos@xxxxxxxxxxx>
Subject: Re: [Gems-users] Compiling problems with transaction.c in Gems 2.0
Luke and Jayaram,

Using the 'as' assembler in /usr/ccs/bin seems to have solved the problem.

Thanks a lot!

Ruben

P.S.: Just for the record, this is the gcc build I used:

bash-3.00# gcc -v
Reading specs from /usr/local/lib/gcc/sparc-sun-solaris2.10/3.4.6/specs
Configured with: ../configure --with-as=/usr/ccs/bin/as --with-ld=/usr/ccs/bin/ld --enable-shared --enable-languages=c,c++,f77
Thread model: posix
gcc version 3.4.6


On 10/9/07, Jayaram Bobba <bobba@xxxxxxxxxxx> wrote:
Ruben,

My guess is that this could be
- a bug in gnu assembler (gas) or
- a bug in gcc or
- bad inline assembly.

To rule out the first two cases, could you recompile with a different
version of gcc / configured to use a different assembler (preferably
'as'). We have
successfully compiled the TM workloads using the following gcc build...

Configured with:
/gates/sfwnv/builds/sfwnv-gate/usr/src/cmd/gcc/gcc-3.4.3/configure
--prefix=/usr/sfw --with-as=/usr/ccs/bin/as --without-gnu-as
--with-ld=/usr/ccs/bin/ld --without-gnu-ld --enable-languages=c,c++,f77
--enable-shared
Thread model: posix
gcc version 3.4.3 (csl-sol210-3_4-20050802)

We have also had problems compiling with the following gcc setup (i
think it uses 'gas')-

Target: sparc-sun-solaris2.10
Configured with:
/export/home/bldmstr/nightly/20060207_gcc2ir.s10.opt.tarbuild/src/configure
--prefix=/opt/gcc --enable-languages=c,c++
Thread model: posix
gcc version 4.0.2 (gccfss)

Jayaram

Rubén Titos wrote:
> Dear list,
>
> I've just set up my gems-2.0 environment and I'm trying to compile the
> transactional microbenchmarks included in the new release. After
> having the files inside my simulated simics machine (a sarek US-III+
> with Solaris 10), my problem is that I can't build any benchmark (nor
> any other workload) since, according to the assembler, there's an
> error in the code generated when compiling the file
> $GEMS/microbenchmarks/transactional/common/transaction.c. I've
> compiled it in two steps to see the assembler code, and to my
> surprise, the assembler finds an "Illegal operand" error in an empty
> line. Here is the output I got inside my sarek/sol10 simics machine,
> and some lines from transaction.s:
>
>
> bash-3.00# cd btree/
> bash-3.00# gmake
> /usr/sfw/bin/gcc -c -O3 -Wa,-xarch=v8plusa -DSIMICS -I../common
> btree_c.c -DNODE_NUM_PAIRS=9 -DNUM_POOLS=1
> /usr/sfw/bin/gcc -c -O3 -Wa,-xarch=v8plusa -DSIMICS -I../common
> btree_c_util.c -DNODE_NUM_PAIRS=9 -DNUM_POOLS=1
> /usr/sfw/bin/gcc -c -O3 -Wa,-xarch=v8plusa -DSIMICS -I../common -o
> transaction.o ../common/transaction.c
> /var/tmp//ccP5j6V5.s: Assembler messages:
> /var/tmp//ccP5j6V5.s:1121: Error: Illegal operands
> gmake: *** [ transaction.o] Error 1
> bash-3.00# /usr/sfw/bin/gcc -S -O3 -Wa,-xarch=v8plusa -DSIMICS
> -I../common -o transaction.s ../common/transaction.c
> bash-3.00# /usr/sfw/bin/gcc -O3 -Wa,-xarch=v8plusa -DSIMICS
> -I../common -o transaction.o ../common/transaction.s
> ../common/transaction.s: Assembler messages:
> ../common/transaction.s:1121: Error: Illegal operands
> bash-3.00# nl ../common/transaction.s
> [...]
>   1110          be      .LL243
>   1111          mov     0, %i0
>   1112          sethi 7, %g0  !magic service 7
>   1113
>   1114          sethi 11, %g0  !magic service 11
>   1115
>   1116          b,a     .LL241
>   1117  .LL243:
>   1118          sethi 7, %g0  !magic service 7
>   1119
>   1120          sethi 28, %g0  !magic service 28
>   1121
>   1122  .LL241:
>   1123          ret
>   1124          restore
>   1125          .size   transaction_manager_stub,
> .-transaction_manager_stub
>   1126          .align 4
>   1127          .global touch_log
>   1128          .type   touch_log, #function
>   1129          .proc   020
>   1130  touch_log:
>
> I'm using Solaris 10 "out-of-the-box", and gcc/gas included in /usr/sfw.
>
> bash-3.00# gcc -v
> Reading specs from /usr/sfw/lib/gcc/sparc-sun-solaris2.10/3.4.3/specs
> Configured with:
> /gates/sfw10/builds/sfw10-gate/usr/src/cmd/gcc/gcc-3.4.3/configure
> --prefix=/usr/sfw --with-as=/usr/sfw/bin/gas --with-gnu-as
> --with-ld=/usr/ccs/bin/ld --without-gnu-ld --enable-languages=c,c++
> --enable-shared
> Thread model: posix
> gcc version 3.4.3 (csl-sol210-3_4-branch+sol_rpath)
>
> Anybody knows what's going on? Could it be a bug in the inline
> assembly code of transaction.c?
>
> Thanks a lot!
>
> Ruben
>
> --
> Ruben Titos
> Parallel Computing and Architecture Group (GACOP)
> Computer Engineering Dept.
> University of Murcia
> ------------------------------------------------------------------------
>
> _______________________________________________
> Gems-users mailing list
> Gems-users@xxxxxxxxxxx
> https://lists.cs.wisc.edu/mailman/listinfo/gems-users
> Use Google to search the GEMS Users mailing list by adding "site: https://lists.cs.wisc.edu/archive/gems-users/" to your search.
>
>

_______________________________________________
Gems-users mailing list
Gems-users@xxxxxxxxxxx
https://lists.cs.wisc.edu/mailman/listinfo/gems-users
Use Google to search the GEMS Users mailing list by adding "site: https://lists.cs.wisc.edu/archive/gems-users/" to your search.




--
Ruben Titos
Parallel Computing and Architecture Group (GACOP)
Computer Engineering Dept.
University of Murcia
[← Prev in Thread] Current Thread [Next in Thread→]