tinycc-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Tinycc-devel] Debian x64 bootstrap error with clang


From: Christian Jullien
Subject: Re: [Tinycc-devel] Debian x64 bootstrap error with clang
Date: Sat, 19 Sep 2020 08:08:55 +0200

Thank you Herman,

Your patch works now with clang on Debian and still works on macOS.

Patch has been pushed on mod.

 

Have a nice day.

 

C.

 

From: Herman ten Brugge [mailto:hermantenbrugge@home.nl]
Sent: Saturday, September 19, 2020 07:47
To: jullien@eligis.com; tinycc-devel@nongnu.org
Subject: Re: [Tinycc-devel] Debian x64 bootstrap error with clang

 

Can you test attached patch.
There might be more places that use __APPLE__ that should be done differently.
You can commit if it works because I cannot test it.

    Herman

On 2020-09-19 06:48, Christian Jullien wrote:

Hi I generally test tcc Linux x64 on Fedora 32, giving a try on an up to date Debian v10.5, while it works with gcc, using clang, I get:

 

jullien@debian64:~/tinycc$ uname -a

Linux debian64 4.19.0-10-amd64 #1 SMP Debian 4.19.132-1 (2020-07-24) x86_64 GNU/Linux

 

jullien@debian64:~/tinycc$ clang -v

clang version 7.0.1-8 (tags/RELEASE_701/final)

Target: x86_64-pc-linux-gnu

 

jullien@debian64:~/tinycc$ ./configure --cc=clang

Binary directory    /usr/local/bin

TinyCC directory    /usr/local/lib/tcc

Library directory   /usr/local/lib

Include directory   /usr/local/include

Manual directory    /usr/local/share/man

Info directory      /usr/local/share/info

Doc directory       /usr/local/share/doc

Source path         /home/jullien/tinycc

C compiler          clang (7.0)

Target OS           Linux

CPU                 x86_64

Triplet             x86_64-linux-gnu

Creating config.mak and config.h

config.h is unchanged

 

jullien@debian64:~/tinycc$ make && make test

...

running tcc.c in threads to run fib

3 2 1 13 8 610 34 2584 144 55 5 21 233 1597 377 987 89 6765 10946 4181

(1497 ms)

compiling tcc.c 10 times

(610 ms)

tcctest.c:3232:10: error: invalid operand for instruction

        __asm__("xchgb %b0,%h0\n\t"     /* swap lower bytes     */

                ^

<inline asm>:1:13: note: instantiated into assembly here

        xchgb %dil,%di

                   ^~~

tcctest.c:3233:17: error: invalid operand for instruction

                "rorl $16,%0\n\t"       /* swap words           */

                              ^

<inline asm>:3:13: note: instantiated into assembly here

        xchgb %dil,%di

                   ^~~

2 errors generated.

make[2]: *** [Makefile:121: test.ref] Error 1

make[1]: *** [Makefile:95: all] Error 2

make[1]: Leaving directory '/home/jullien/tinycc/tests'

make: *** [Makefile:393: test] Error 2

 


reply via email to

[Prev in Thread] Current Thread [Next in Thread]