1. 19 Aug, 2023 13 commits
  2. 18 Aug, 2023 4 commits
  3. 25 Apr, 2023 6 commits
    • grischka's avatar
      about CONST_WANTED & VT_NONCONST · 0ec3a40d
      grischka authored
      - integrate CONST_WANTED with nocode_wanted
      - expr_const() checks VT_NONCONST
      0ec3a40d
    • grischka's avatar
      stuff & etc.. · bb93bf8c
      grischka authored
      - tccpp.c: rename ... to __TCC_BCHECK__/__TCC_BACKTRACE__
      - libtcc.c: correct total line count
      - libtcc.c: support -run -- args... (instead of -run @ args ...)
      - Makefile/build-tcc.bat: streamline GITHASH string somewhat
      - bt-exe.c: avoid redef of pstrcpy() with 'tcc -bt tcc.c ...'
      bb93bf8c
    • grischka's avatar
      CStrings leakless · a0454005
      grischka authored
      avoid memory leaks with lost CStrings on stack after errors.
      
      tccpp.c:
      - use/abuse static Cstring tokcstr where possible
      tccgen.c:
      - use/abuse static Cstring initstr where possible
      tcc.h/libtcc.a:
      - add 'stk_data' array to track memory pointer on stack
      - add macros stk_push/pop() and cstr_new/free_s()
      tccasm.c:
      - use that
      - use char[16] instead of char* for op.constraint
      a0454005
    • grischka's avatar
      MEM_DEBUG thread-safe & tccdbg leakless · 40131b7e
      grischka authored
      libtcc.c:
      - guard tcc_realloc/free_debug() with a semaphore
      tccdbg.c:
      - allow tcc_debug_end() to be called twice safely
      40131b7e
    • grischka's avatar
      tcc_error_noabort(): always use this unless compiling · 7916cf71
      grischka authored
      This avoids 'exit(1)' with errors outside of compilation
      (nasty in particular with libtcc usage)
      
      As a sideeffect multiple errors can be seen for linker
      errors (such as undefined symbols, relocation errors, ...)
      7916cf71
    • grischka's avatar
      lib/armeabi.c: fix zero from/to double conversion · 19ef024a
      grischka authored
      tccgen.c:
      - allow cross-compiling 0.0L (cross-compile tcc with tcc)
      tccelf.c:
      - use alignment of TLS section for PT_TLS
      tccpp.c:
      - support long double constants on systems that do not support
        long doubles (i.e. mark them (VT_DOUBLE | VT_LONG))
      tccdefs.h:
        #define __has_feature() for android
        remove _unaligned (why define a msvc extension under !_WIN32)
      19ef024a
  4. 20 Apr, 2023 1 commit
  5. 15 Apr, 2023 2 commits
  6. 08 Apr, 2023 1 commit
  7. 23 Mar, 2023 2 commits
  8. 18 Mar, 2023 2 commits
  9. 13 Mar, 2023 1 commit
    • Michael Matz's avatar
      Fix 128_run_atexit.c on linux · 4dc4e93f
      Michael Matz authored
      if we include standard headers on glibc-based systems then
      we can't use '__attribute__' (those are defined away for unknown
      compilers) but must use '__attribute' (or #undef that token).
      4dc4e93f
  10. 12 Mar, 2023 2 commits
    • grischka's avatar
      small scopes cleanup etc. · 19e3e10e
      grischka authored
      tccgen.c:
      - just track local_stack for small scopes (can't declare variables)
      - fix a vla problem with nested scopes
      - move debug N_L/RBRAC into curly braced block
      
      Also:
      - tccpp.c: move 'label_...' functions to tccgen.c
      - tccpp.c: let get_tok_str() say "<no name>" for anonymous symbols
      - tcctest.c: let __pa_symbol() work for memory > 2GB
      - 119_random_stuff.c: revert strtoll test (no reason to test libc)
      - tccdefs.h/tcctest.c: enable bit fncs for _WIN32
      - Makefile:
        - use i686-linux-gnu instead of i386-linux-gnu for cross-i386
        - update 'make help'
        - revert umplicit 'make all' with 'make install' (but print warning)
      19e3e10e
    • grischka's avatar
      Revert ""Fix" nocode_wanted in expr_landor" · 5f08561e
      grischka authored
      instead in vcheck_cmp(), pass the CODE_OFF_BIT to generators
      unless other nocode purposes are set.
      
      This reverts commit cad87395.
      
      Also in 128_run_atexit.c:
      avoid line output disorder which may happen on windows when
      tcc itself and runned code are using two different printf
      implementations and tcc would print the "[Returns 1]" above
      any output from the runned test.
      5f08561e
  11. 11 Mar, 2023 4 commits
  12. 10 Mar, 2023 2 commits
    • Michael Matz's avatar
      Fix type of cond-op · ef3eb02c
      Michael Matz authored
      the optimization of a ternary op with two boolean operands had
      the same problem (as in the last commit) of loosing the type.
      ef3eb02c
    • Michael Matz's avatar
      Fix casted boolean expressions · 96b31ba6
      Michael Matz authored
      the casted type was lost when a delayed bool was finally converted
      to a value.  See testcase, in the wrong case the '(unsigned int)' cast
      was ignored, and hence the division was signed reulting in -1 instead of
      the proper 0x7fffffff.
      96b31ba6