From 7f1ab9b1e111b9ea9261eec4b7c6fb0f42591eef Mon Sep 17 00:00:00 2001 From: grischka Date: Sun, 16 Jul 2017 12:10:00 +0200 Subject: tccgen: nodata_wanted The existing variable 'nocode_wanted' is now used to control output of static data too. So... (nocode_wanted == 0) code and data (normal within functions) (nocode_wanted < 0) means: no code, but data (global or static data) (nocode_wanted > 0) means: no code and no data (code and data suppressed) (nocode_wanted & 0xC0000000) means: we're in declaration of static data Also: new option '-dT' to be used with -run tcc -dT -run file.c This will look in file.c for certain comment-boundaries: /*-* test-xxx: ...some description */ and then for each test below run it from memory. This way various features and error messages can be tested with one single file. See 96_nodata_wanted.c for an example. Also: tccgen.c: one more bitfield fix --- tests/tests2/95_bitfields_ms.expect | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'tests/tests2/95_bitfields_ms.expect') diff --git a/tests/tests2/95_bitfields_ms.expect b/tests/tests2/95_bitfields_ms.expect index f4eb2d3..6b5c3f9 100644 --- a/tests/tests2/95_bitfields_ms.expect +++ b/tests/tests2/95_bitfields_ms.expect @@ -23,8 +23,8 @@ values : 03 ffffffff 0f fffffff8 78 align/size : 4 8 ---- TEST 5 - MS-BITFIELDS ---- -bits in use : 00000000FFFF00FF0000003FFFFFFFFF00000007FFFFFFFF00001FFFFFFFFFFF -bits as set : 0000000000770044000000000000007800000007F00000000000000123456789 +bits in use : 00000000FFFF00FF0000003FFFFFFFFF000000003FFFFFFF00001FFFFFFFFFFF +bits as set : 0000000000770044000000000000007800000000300000000000000123456789 values : 0000000123456789 fffffffff0000000 0000000000000078 44 77 align/size : 8 32 @@ -61,8 +61,8 @@ values : 03 ffffffff 0f fffffff8 78 align/size : 1 8 ---- TEST 5 - MS-BITFIELDS - PACKED ---- -bits in use : FFFFFF0000003FFFFFFFFF00000007FFFFFFFF00001FFFFFFFFFFF -bits as set : 007744000000000000007800000007F00000000000000123456789 +bits in use : FFFFFF0000003FFFFFFFFF000000003FFFFFFF00001FFFFFFFFFFF +bits as set : 007744000000000000007800000000300000000000000123456789 values : 0000000123456789 fffffffff0000000 0000000000000078 44 77 align/size : 1 27 @@ -99,8 +99,8 @@ values : 03 ffffffff 0f fffffff8 78 align/size : 4 8 ---- TEST 5 - MS-BITFIELDS - WITH ALIGN ---- -bits in use : 00000000FFFF00FF0000003FFFFFFFFF00000007FFFFFFFF00001FFFFFFFFFFF -bits as set : 0000000000770044000000000000007800000007F00000000000000123456789 +bits in use : 00000000FFFF00FF0000003FFFFFFFFF000000003FFFFFFF00001FFFFFFFFFFF +bits as set : 0000000000770044000000000000007800000000300000000000000123456789 values : 0000000123456789 fffffffff0000000 0000000000000078 44 77 align/size : 8 32 @@ -137,8 +137,8 @@ values : 03 ffffffff 0f fffffff8 78 align/size : 1 8 ---- TEST 5 - MS-BITFIELDS - PACKED - WITH ALIGN ---- -bits in use : FFFFFF0000003FFFFFFFFF00000007FFFFFFFF00001FFFFFFFFFFF -bits as set : 007744000000000000007800000007F00000000000000123456789 +bits in use : FFFFFF0000003FFFFFFFFF000000003FFFFFFF00001FFFFFFFFFFF +bits as set : 007744000000000000007800000000300000000000000123456789 values : 0000000123456789 fffffffff0000000 0000000000000078 44 77 align/size : 1 27 -- cgit v1.3.1