[Top][All Lists]

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

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

From: Herman ten Brugge
Subject: Re: [Tinycc-devel] Debian x64 bootstrap error with clang
Date: Sat, 19 Sep 2020 07:47:14 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.11.0

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.


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

Attachment: patch
Description: Text document

reply via email to

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