Changes in directory llvm-test/SingleSource/UnitTests/Integer:
SSAtest.c updated: 1.3 -> 1.4 arith.c updated: 1.3 -> 1.4 array.c updated: 1.3 -> 1.4 bigint.c updated: 1.3 -> 1.4 bitbit.c updated: 1.3 -> 1.4 bitlogic.c updated: 1.3 -> 1.4 cppfield.cpp updated: 1.1 -> 1.2 enum.cpp updated: 1.3 -> 1.4 exception.cpp updated: 1.2 -> 1.3 extern-inline-redef.c updated: 1.3 -> 1.4 field.c updated: 1.2 -> 1.3 folding.c updated: 1.2 -> 1.3 general-test.c updated: 1.3 -> 1.4 global.c updated: 1.2 -> 1.3 large-array.c updated: 1.3 -> 1.4 list.c updated: 1.3 -> 1.4 local-array.c updated: 1.3 -> 1.4 local-union.c updated: 1.3 -> 1.4 matrix.c updated: 1.4 -> 1.5 matrix.reference_output updated: 1.1 -> 1.2 memory.c updated: 1.3 -> 1.4 offset.c updated: 1.3 -> 1.4 override.cpp updated: 1.3 -> 1.4 pointer.c updated: 1.3 -> 1.4 static.c updated: 1.2 -> 1.3 struct1.c updated: 1.3 -> 1.4 struct2.c updated: 1.3 -> 1.4 structInit.c updated: 1.3 -> 1.4 switch.c updated: 1.3 -> 1.4 template.cpp updated: 1.3 -> 1.4 template2.cpp updated: 1.2 -> 1.3 template3.cpp updated: 1.3 -> 1.4 union-init.c updated: 1.3 -> 1.4 union-struct.c updated: 1.3 -> 1.4 union2.c updated: 1.2 -> 1.3 --- Log message: Fixed some errors in the testcases and added license titles. --- Diffs of the changes: (+371 -243) SSAtest.c | 10 +- arith.c | 10 +- array.c | 10 +- bigint.c | 10 +- bitbit.c | 10 +- bitlogic.c | 10 +- cppfield.cpp | 5 + enum.cpp | 10 +- exception.cpp | 10 +- extern-inline-redef.c | 10 +- field.c | 26 +++++-- folding.c | 10 +- general-test.c | 5 + global.c | 12 ++- large-array.c | 10 +- list.c | 32 +++++++- local-array.c | 10 +- local-union.c | 10 +- matrix.c | 171 ++++++++++++++++++++++++++---------------------- matrix.reference_output | 72 ++------------------ memory.c | 14 ++- offset.c | 10 +- override.cpp | 10 +- pointer.c | 10 +- static.c | 10 +- struct1.c | 10 +- struct2.c | 10 +- structInit.c | 10 +- switch.c | 18 +++-- template.cpp | 10 +- template2.cpp | 10 +- template3.cpp | 9 +- union-init.c | 10 +- union-struct.c | 10 +- union2.c | 10 +- 35 files changed, 371 insertions(+), 243 deletions(-) Index: llvm-test/SingleSource/UnitTests/Integer/SSAtest.c diff -u llvm-test/SingleSource/UnitTests/Integer/SSAtest.c:1.3 llvm-test/SingleSource/UnitTests/Integer/SSAtest.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/SSAtest.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/SSAtest.c Mon Jan 22 14:47:27 2007 @@ -1,10 +1,14 @@ -//===--- SSAtest.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- SSAtest.c --- Test Cases for Bit Accurate Types ----------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // Adopted the test from previous test-cases. Changed it with // non-regular int data type. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> typedef int __attribute__ ((bitwidth(4))) int4; Index: llvm-test/SingleSource/UnitTests/Integer/arith.c diff -u llvm-test/SingleSource/UnitTests/Integer/arith.c:1.3 llvm-test/SingleSource/UnitTests/Integer/arith.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/arith.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/arith.c Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- arith.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- arith.c --- Test Cases for Bit Accurate Types ------------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a general test for arithmatic operations. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include "arith.h" #include <stdio.h> Index: llvm-test/SingleSource/UnitTests/Integer/array.c diff -u llvm-test/SingleSource/UnitTests/Integer/array.c:1.3 llvm-test/SingleSource/UnitTests/Integer/array.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/array.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/array.c Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- array.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- array.c --- Test Cases for Bit Accurate Types ------------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a general test for array data types. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include "array.h" #include <stdio.h> Index: llvm-test/SingleSource/UnitTests/Integer/bigint.c diff -u llvm-test/SingleSource/UnitTests/Integer/bigint.c:1.3 llvm-test/SingleSource/UnitTests/Integer/bigint.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/bigint.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/bigint.c Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- bigint.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- bigint.c --- Test Cases for Bit Accurate Types -----------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a general test for big integer type. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include "bigint.h" #include <stdio.h> Index: llvm-test/SingleSource/UnitTests/Integer/bitbit.c diff -u llvm-test/SingleSource/UnitTests/Integer/bitbit.c:1.3 llvm-test/SingleSource/UnitTests/Integer/bitbit.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/bitbit.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/bitbit.c Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- bitbit.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- bitbit.c --- Test Cases for Bit Accurate Types -----------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a general test for bit operations. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include "bitbit.h" #include <stdio.h> Index: llvm-test/SingleSource/UnitTests/Integer/bitlogic.c diff -u llvm-test/SingleSource/UnitTests/Integer/bitlogic.c:1.3 llvm-test/SingleSource/UnitTests/Integer/bitlogic.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/bitlogic.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/bitlogic.c Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- bitlogic.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- bitlogic.c --- Test Cases for Bit Accurate Types ---------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a general test for logical operations. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include "bitlogic.h" #include <stdio.h> Index: llvm-test/SingleSource/UnitTests/Integer/cppfield.cpp diff -u llvm-test/SingleSource/UnitTests/Integer/cppfield.cpp:1.1 llvm-test/SingleSource/UnitTests/Integer/cppfield.cpp:1.2 --- llvm-test/SingleSource/UnitTests/Integer/cppfield.cpp:1.1 Thu Jan 18 20:22:46 2007 +++ llvm-test/SingleSource/UnitTests/Integer/cppfield.cpp Mon Jan 22 14:47:27 2007 @@ -1,4 +1,9 @@ #include <stdio.h> +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// typedef unsigned int __attribute__ ((bitwidth(7))) int7; typedef unsigned int __attribute__ ((bitwidth(17))) int17; typedef unsigned int __attribute__ ((bitwidth(32))) int32; Index: llvm-test/SingleSource/UnitTests/Integer/enum.cpp diff -u llvm-test/SingleSource/UnitTests/Integer/enum.cpp:1.3 llvm-test/SingleSource/UnitTests/Integer/enum.cpp:1.4 --- llvm-test/SingleSource/UnitTests/Integer/enum.cpp:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/enum.cpp Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- enum.cpp --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- enum.cpp --- Test Cases for Bit Accurate Types -----------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test of bitwidth attribute with enum data. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> class myClass Index: llvm-test/SingleSource/UnitTests/Integer/exception.cpp diff -u llvm-test/SingleSource/UnitTests/Integer/exception.cpp:1.2 llvm-test/SingleSource/UnitTests/Integer/exception.cpp:1.3 --- llvm-test/SingleSource/UnitTests/Integer/exception.cpp:1.2 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/exception.cpp Mon Jan 22 14:47:27 2007 @@ -1,10 +1,14 @@ -//===--- exception.cpp --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- exception.cpp --- Test Cases for Bit Accurate Types ------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test of exception handling with non-regular data // type. The compiler should be able to differentiate int31, int7 etc. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> typedef int __attribute__ ((bitwidth(31))) int31; Index: llvm-test/SingleSource/UnitTests/Integer/extern-inline-redef.c diff -u llvm-test/SingleSource/UnitTests/Integer/extern-inline-redef.c:1.3 llvm-test/SingleSource/UnitTests/Integer/extern-inline-redef.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/extern-inline-redef.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/extern-inline-redef.c Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- extern_inline_redef.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- extern_inline_redef.c --- Test Cases for Bit Accurate Types ----===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // this is used to test redefining inline function. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> typedef int __attribute__ ((bitwidth(61))) int61; Index: llvm-test/SingleSource/UnitTests/Integer/field.c diff -u llvm-test/SingleSource/UnitTests/Integer/field.c:1.2 llvm-test/SingleSource/UnitTests/Integer/field.c:1.3 --- llvm-test/SingleSource/UnitTests/Integer/field.c:1.2 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/field.c Mon Jan 22 14:47:27 2007 @@ -1,18 +1,27 @@ -//===--- field.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- field.c --- Test Cases for Bit Accurate Types ------------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is used to test struct with field specifier. We suppose the -// data layout of the field should be the same as the corresponding struct using -// bit accurate types. +// data layout of the field should be the same as the corresponding +// struct using bit accurate types. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> typedef int __attribute__ ((bitwidth(7))) int7; typedef int __attribute__ ((bitwidth(17))) int17; typedef int __attribute__ ((bitwidth(32))) int32; typedef int __attribute__ ((bitwidth(8))) int8; -typedef struct myStruct{int i; unsigned char c :7; int s: 17; char c2;} myStruct; +typedef long __attribute__ ((bitwidth(33))) long33; +typedef char __attribute__ ((bitwidth(7))) char7; +typedef short __attribute__ ((bitwidth(17))) short17; + +typedef struct myStruct{int i; unsigned char c:7; int s:17; char c2;} myStruct; + typedef struct myStruct2{int32 i; int7 c; int17 s; int8 c2;} myStruct2; int main() @@ -23,6 +32,8 @@ void* ptr, *ptr1, *ptr2, *ptr3; unsigned int offset, offset1; + // printf("sizeof(int7) = %d, sizeof(int17) = %d, sizeof(int33) = %d\n", + // sizeof(char7), sizeof(short17), sizeof(long33)); ptr = &(x.i); ptr1 = &(x.c2); @@ -35,7 +46,8 @@ if(offset != offset1) printf("error: offset=%x, offset1=%x\n", offset, offset1); if(sizeof(myStruct) != sizeof(myStruct2)) - printf("error2: sizeof myStruct = %d, sizeof myStruct2 = %d\n", sizeof(myStruct), sizeof(myStruct2)); + printf("error2: sizeof myStruct = %d, sizeof myStruct2 = %d\n", + sizeof(myStruct), sizeof(myStruct2)); return 0; } Index: llvm-test/SingleSource/UnitTests/Integer/folding.c diff -u llvm-test/SingleSource/UnitTests/Integer/folding.c:1.2 llvm-test/SingleSource/UnitTests/Integer/folding.c:1.3 --- llvm-test/SingleSource/UnitTests/Integer/folding.c:1.2 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/folding.c Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- folding.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- folding.c --- Test Cases for Bit Accurate Types ----------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is used to test constant folding optimization. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> typedef int __attribute__ ((bitwidth(7))) int7; Index: llvm-test/SingleSource/UnitTests/Integer/general-test.c diff -u llvm-test/SingleSource/UnitTests/Integer/general-test.c:1.3 llvm-test/SingleSource/UnitTests/Integer/general-test.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/general-test.c:1.3 Fri Jan 19 16:24:05 2007 +++ llvm-test/SingleSource/UnitTests/Integer/general-test.c Mon Jan 22 14:47:27 2007 @@ -1,4 +1,9 @@ /* This test just tries out a few bitwidth attribute constructs and +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// * generates some output based on the them. */ Index: llvm-test/SingleSource/UnitTests/Integer/global.c diff -u llvm-test/SingleSource/UnitTests/Integer/global.c:1.2 llvm-test/SingleSource/UnitTests/Integer/global.c:1.3 --- llvm-test/SingleSource/UnitTests/Integer/global.c:1.2 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/global.c Mon Jan 22 14:47:27 2007 @@ -1,15 +1,19 @@ -//===--- global.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- global.c --- Test Cases for Bit Accurate Types -----------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is used to test global arrays. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> typedef int __attribute__ ((bitwidth(7))) int7; typedef int __attribute__ ((bitwidth(14))) int14; -int7 array[4] = {127, -1, 100 -28}; +int7 array[4] = {127, -1, 100, -28}; int14 array2[4][4]; void test() Index: llvm-test/SingleSource/UnitTests/Integer/large-array.c diff -u llvm-test/SingleSource/UnitTests/Integer/large-array.c:1.3 llvm-test/SingleSource/UnitTests/Integer/large-array.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/large-array.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/large-array.c Mon Jan 22 14:47:27 2007 @@ -1,10 +1,14 @@ -//===--- large-array.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- large-array.c --- Test Cases for Bit Accurate Types ------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is used to test large local arrays. Some local arrays are // partially initilized. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> Index: llvm-test/SingleSource/UnitTests/Integer/list.c diff -u llvm-test/SingleSource/UnitTests/Integer/list.c:1.3 llvm-test/SingleSource/UnitTests/Integer/list.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/list.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/list.c Mon Jan 22 14:47:27 2007 @@ -1,10 +1,16 @@ -//===--- list.c --- Test Cases for Bit Accurate Types ---------------------===// +//===--- list.c --- Test Cases for Bit Accurate Types -------------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for simple linked list operation. Data are added to // and removed from the list. We compare the expected value wehen we // remove data from the list. // -//===----------------------------------------------------------------------===// +//===--------------------------------------------------------------------===// + #include <stdio.h> #include <stdlib.h> @@ -14,7 +20,21 @@ typedef struct myStruct{int9 x; int7 y; } myStruct; typedef struct myList{myStruct s; struct myList* next;} myList; -int array[64*3] = {103, 198, 105, 115, 81, 255, 74, 236, 41, 205, 186, 171, 242, 251, 227, 70, 124, 194, 84, 248, 27, 232, 231, 141, 118, 90, 46, 99, 51, 159, 201, 154, 102, 50, 13, 183, 49, 88, 163, 90, 37, 93, 5, 23, 88, 233, 94, 212, 171, 178, 205, 198, 155, 180, 84, 17, 14, 130, 116, 65, 33, 61, 220, 135, 112, 233, 62, 161, 65, 225, 252, 103, 62, 1, 126, 151, 234, 220, 107, 150, 143, 56, 92, 42, 236, 176, 59, 251, 50, 175, 60, 84, 236, 24, 219, 92, 2, 26, 254, 67, 251, 250, 170, 58, 251, 41, 209, 230, 5, 60, 124, 148, 117, 216, 190, 97, 137, 249, 92, 187, 168, 153, 15, 149, 177, 235, 241, 179, 5, 239, 247, 0, 233, 161, 58, 229, 202, 11, 203, 208, 72, 71, 100, 189, 31, 35, 30, 168, 28, 123, 100, 197, 20, 115, 90, 197, 94, 75, 121, 99, 59, 112, 100, 36, 17, 158, 9, 220, 170, 212, 172, 242, 27, 16, 175, 59, 51, 205, 227, 80, 72, 71, 21, 92, 187, 111, 34, 25, 186, 155, 125, 245 +int array[64*3] = {103, 198, 105, 115, 81, 255, 74, 236, 41, 205, 186, 171, + 242, 251, 227, 70, 124, 194, 84, 248, 27, 232, 231, 141, + 118, 90, 46, 99, 51, 159, 201, 154, 102, 50, 13, 183, 49, + 88, 163, 90, 37, 93, 5, 23, 88, 233, 94, 212, 171, 178, + 205, 198, 155, 180, 84, 17, 14, 130, 116, 65, 33, 61, 220, + 135, 112, 233, 62, 161, 65, 225, 252, 103, 62, 1, 126, 151, + 234, 220, 107, 150, 143, 56, 92, 42, 236, 176, 59, 251, 50, + 175, 60, 84, 236, 24, 219, 92, 2, 26, 254, 67, 251, 250, + 170, 58, 251, 41, 209, 230, 5, 60, 124, 148, 117, 216, 190, + 97, 137, 249, 92, 187, 168, 153, 15, 149, 177, 235, 241, + 179, 5, 239, 247, 0, 233, 161, 58, 229, 202, 11, 203, 208, + 72, 71, 100, 189, 31, 35, 30, 168, 28, 123, 100, 197, 20, + 115, 90, 197, 94, 75, 121, 99, 59, 112, 100, 36, 17, 158, + 9, 220, 170, 212, 172, 242, 27, 16, 175, 59, 51, 205, 227, + 80, 72, 71, 21, 92, 187, 111, 34, 25, 186, 155, 125, 245 }; void test() @@ -42,9 +62,11 @@ myList* tmp; i+=1; if(head->s.x != array[64*3 - i]) - printf("error: i = %d, x = %d, array = %d\n", i,head->s.x, array[64*3 - i]); + printf("error: i = %d, x = %d, array = %d\n", + i,head->s.x, array[64*3 - i]); if( (head->s.y ^ (int7)((array[64*3 - i] - 1)&0x7f)) != 0 ) - printf("error: i = %d, y = %hhd, expected = %hhd\n", i, (unsigned char)(head->s.y), ((array[64*3 - i] - 1)&0x7f)); + printf("error: i = %d, y = %hhd, expected = %hhd\n", + i, (unsigned char)(head->s.y), ((array[64*3 - i] - 1)&0x7f)); //remove from the list tmp = head; head = head->next; Index: llvm-test/SingleSource/UnitTests/Integer/local-array.c diff -u llvm-test/SingleSource/UnitTests/Integer/local-array.c:1.3 llvm-test/SingleSource/UnitTests/Integer/local-array.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/local-array.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/local-array.c Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- local-array.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- local-array.c --- Test Cases for Bit Accurate Types ------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is another test for local arrays. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> typedef int __attribute__ ((bitwidth(4))) int4; Index: llvm-test/SingleSource/UnitTests/Integer/local-union.c diff -u llvm-test/SingleSource/UnitTests/Integer/local-union.c:1.3 llvm-test/SingleSource/UnitTests/Integer/local-union.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/local-union.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/local-union.c Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- local-union.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- local-union.c --- Test Cases for Bit Accurate Types ------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for local union data type. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> Index: llvm-test/SingleSource/UnitTests/Integer/matrix.c diff -u llvm-test/SingleSource/UnitTests/Integer/matrix.c:1.4 llvm-test/SingleSource/UnitTests/Integer/matrix.c:1.5 --- llvm-test/SingleSource/UnitTests/Integer/matrix.c:1.4 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/matrix.c Mon Jan 22 14:47:27 2007 @@ -1,110 +1,125 @@ -//===--- matrix.c --- Test Cases for Bit Accurate Types -------------------===// +//===--- matrix.c --- Test Cases for Bit Accurate Types -----------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for matrix with non-regular bitwidth data. In // my_test(A, B) function, we get A=A*B. For each row after // multiplication, we sort it in non-increasing order. Then the first // two largest elements are used to get the gcd. // -//===----------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include "matrix.h" #include <stdio.h> #include <stdlib.h> typedef enum bool{false=0, true=1} bool; -void mysort(const int17 X[8], int17 Y[8]){ -{ - unsigned int i, j; - int17 temp; - { - j = 0; - for ( ; ; ) { - bool ssdm_tmp_4 = (j < 8); - if (!ssdm_tmp_4) break; - Y[j] = X[j]; - j++; - } - } - { - j = 0; - for ( ; ; ) { - bool ssdm_tmp_5 = (j < 8); - if (!ssdm_tmp_5) break; - { - temp = -0xffff; - { - i = j; - for ( ; ; ) { - bool ssdm_tmp_6 = (i < 8); - if (!ssdm_tmp_6) break; - { - temp = Y[i] > temp ? Y[i] : temp; - } - ++i; - } - } - Y[j] = temp; - } - j++; - } - } -} -} -// Module | Test -// Thread: int my_test(sc_int<17> A[8][8], sc_int<17> B[8][8] ); -int my_test(int17 A[8][8], int17 B[8][8]){ + + + + +void mysort(const int17 X[8], int17 Y[8]) { - unsigned int i, j, k; - int17 C[8]; - int t; - { - i = 0; - for ( ; ; ) { - bool ssdm_tmp_1 = (i < 8); - if (!ssdm_tmp_1) break; + unsigned int i, j; + int17 temp; { - j = 0; - for ( ; ; ) { - bool ssdm_tmp_2 = (j < 8); - if (!ssdm_tmp_2) break; - { - { - k = 0; + j = 0; for ( ; ; ) { - bool ssdm_tmp_3 = (k < 8); - if (!ssdm_tmp_3) break; - A[i][j] = A[i][k] * B[j][k]; - ++k; + bool ssdm_tmp_4 = (j < 8); + if (!ssdm_tmp_4) break; + Y[j] = X[j]; + j++; } - } - mysort(A[i], C); - t = get_gcd(C[0], C[1]); - printf("t=%d\n", t); - } - ++j; } + { + j = 0; + for ( ; ;j++ ) { + bool ssdm_tmp_5 = (j < 8); + if (!ssdm_tmp_5) break; + { + i = j; + for ( ; ; i++) { + bool ssdm_tmp_6 = (i < 8); + if (!ssdm_tmp_6) break; + { + if(Y[i]>Y[j]){ + temp = Y[j]; + Y[j] = Y[i]; + Y[i] = temp; + } + + } + } + } + + } } - ++i; - } - } - return 0; } -} -// Thread: int get_gcd(const int& a, const int& b); -int get_gcd(const int a, const int b){ + + + +int get_gcd(const int a, const int b) { - if (b == 0/*CPPASTBinaryExpression*/) + if (b == 0) return a; return get_gcd( b, a % b ); } + + + +int my_test(int17 A[8][8], int17 B[8][8]) +{ + unsigned int i, j, k, dd; + int17 C[8][8]; + int17 D[8]; + int t; + { + i = 0; + for ( ; ; ) { + bool ssdm_tmp_1 = (i < 8); + if (!ssdm_tmp_1) break; + { + j = 0; + for ( ; ; ) { + bool ssdm_tmp_2 = (j < 8); + if (!ssdm_tmp_2) break; + { + { + C[i][j] = 0; + k = 0; + for ( ; ; ) { + bool ssdm_tmp_3 = (k < 8); + if (!ssdm_tmp_3) break; + C[i][j] += A[i][k] * B[k][j]; + ++k; + } + } + + } + + ++j; + } + } + mysort(C[i], D); + t = get_gcd(D[0], D[1]); + printf("get_gcd(%d, %d) = %d\n", D[0], D[1], t); + ++i; + } + } + return 0; } + + + int main() { - unsigned int i, j; + int i, j; int17 X[8][8]; int17 Y[8][8]; Index: llvm-test/SingleSource/UnitTests/Integer/matrix.reference_output diff -u llvm-test/SingleSource/UnitTests/Integer/matrix.reference_output:1.1 llvm-test/SingleSource/UnitTests/Integer/matrix.reference_output:1.2 --- llvm-test/SingleSource/UnitTests/Integer/matrix.reference_output:1.1 Thu Jan 18 20:22:46 2007 +++ llvm-test/SingleSource/UnitTests/Integer/matrix.reference_output Mon Jan 22 14:47:27 2007 @@ -1,65 +1,9 @@ -t=86 -t=86 -t=22532 -t=45064 -t=45064 -t=45064 -t=45064 -t=45064 -t=172 -t=172 -t=45064 -t=45064 -t=45064 -t=49184 -t=49184 -t=49184 -t=2 -t=2 -t=2 -t=4 -t=4 -t=4 -t=4 -t=4 -t=8 -t=8 -t=8 -t=49184 -t=49184 -t=49184 -t=57424 -t=57424 -t=2 -t=2 -t=2 -t=2 -t=2 -t=57424 -t=57424 -t=57424 -t=516 -t=516 -t=4120 -t=8240 -t=12360 -t=16480 -t=20600 -t=20600 -t=602 -t=602 -t=26652 -t=53304 -t=53304 -t=53304 -t=53304 -t=53304 -t=688 -t=688 -t=49184 -t=49184 -t=49184 -t=49184 -t=49184 -t=49184 +get_gcd(50088, 48396) = 12 +get_gcd(-30896, -34280) = -8 +get_gcd(19192, 14116) = 4 +get_gcd(62512, 55744) = 16 +get_gcd(60148, -11704) = -44 +get_gcd(38384, 28232) = 8 +get_gcd(64784, 52940) = 4 +get_gcd(57344, 43808) = 32 exit 0 Index: llvm-test/SingleSource/UnitTests/Integer/memory.c diff -u llvm-test/SingleSource/UnitTests/Integer/memory.c:1.3 llvm-test/SingleSource/UnitTests/Integer/memory.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/memory.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/memory.c Mon Jan 22 14:47:27 2007 @@ -1,9 +1,15 @@ -//===--- memory.c --- Test Cases for Bit Accurate Types -------------------===// +//===--- memory.c --- Test Cases for Bit Accurate Types -----------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for memory malloc and free operations. It tests // non-regular bitwidth data and structures. // -//===----------------------------------------------------------------------===// +//===--------------------------------------------------------------------===// + #include <stdio.h> #include <stdlib.h> @@ -17,7 +23,7 @@ int inum = num; unsigned int i = 0; - int31* array = malloc(sizeof(int3) * inum); + int31* array = (int31*) malloc(sizeof(int31) * inum); for(i=0; i< num; ++i) { array[i] = i; @@ -29,7 +35,7 @@ void mem_test2() { myStruct* ptr = malloc(sizeof(myStruct)); - ptr->y = 8; // constant 0 + ptr->y = 0; if(ptr->y != 0) printf("error\n"); ptr->x = ++(ptr->y); Index: llvm-test/SingleSource/UnitTests/Integer/offset.c diff -u llvm-test/SingleSource/UnitTests/Integer/offset.c:1.3 llvm-test/SingleSource/UnitTests/Integer/offset.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/offset.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/offset.c Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- offset.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- offset.c --- Test Cases for Bit Accurate Types -----------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for data size calculation with non-regular integral type. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> Index: llvm-test/SingleSource/UnitTests/Integer/override.cpp diff -u llvm-test/SingleSource/UnitTests/Integer/override.cpp:1.3 llvm-test/SingleSource/UnitTests/Integer/override.cpp:1.4 --- llvm-test/SingleSource/UnitTests/Integer/override.cpp:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/override.cpp Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- override.cpp --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- override.cpp --- Test Cases for Bit Accurate Types -------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test of override test. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> typedef int __attribute__ ((bitwidth(31))) int31; typedef int __attribute__ ((bitwidth(32))) int32; Index: llvm-test/SingleSource/UnitTests/Integer/pointer.c diff -u llvm-test/SingleSource/UnitTests/Integer/pointer.c:1.3 llvm-test/SingleSource/UnitTests/Integer/pointer.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/pointer.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/pointer.c Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- pointer.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- pointer.c --- Test Cases for Bit Accurate Types ----------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for address calculation with non-regular integral type. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> typedef int __attribute__ ((bitwidth(3))) int3; Index: llvm-test/SingleSource/UnitTests/Integer/static.c diff -u llvm-test/SingleSource/UnitTests/Integer/static.c:1.2 llvm-test/SingleSource/UnitTests/Integer/static.c:1.3 --- llvm-test/SingleSource/UnitTests/Integer/static.c:1.2 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/static.c Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- static.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- static.c --- Test Cases for Bit Accurate Types -----------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for static data with non-regular integral data. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> typedef int __attribute__ ((bitwidth(31))) int31; Index: llvm-test/SingleSource/UnitTests/Integer/struct1.c diff -u llvm-test/SingleSource/UnitTests/Integer/struct1.c:1.3 llvm-test/SingleSource/UnitTests/Integer/struct1.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/struct1.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/struct1.c Mon Jan 22 14:47:27 2007 @@ -1,10 +1,14 @@ -//===--- struct1.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- struct1.c --- Test Cases for Bit Accurate Types ----------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for struct data structure. If the data layout for // non-regular bitwidth data is not correct, it may change the value of another field. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> Index: llvm-test/SingleSource/UnitTests/Integer/struct2.c diff -u llvm-test/SingleSource/UnitTests/Integer/struct2.c:1.3 llvm-test/SingleSource/UnitTests/Integer/struct2.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/struct2.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/struct2.c Mon Jan 22 14:47:27 2007 @@ -1,10 +1,14 @@ -//===--- struct2.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- struct2.c --- Test Cases for Bit Accurate Types ----------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for struct data structure. We test the nested structure // and pointer to structure. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> Index: llvm-test/SingleSource/UnitTests/Integer/structInit.c diff -u llvm-test/SingleSource/UnitTests/Integer/structInit.c:1.3 llvm-test/SingleSource/UnitTests/Integer/structInit.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/structInit.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/structInit.c Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- structInit.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- structInit.c --- Test Cases for Bit Accurate Types -------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for struct data structure with initialization. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> typedef int __attribute__ ((bitwidth(31))) int31; Index: llvm-test/SingleSource/UnitTests/Integer/switch.c diff -u llvm-test/SingleSource/UnitTests/Integer/switch.c:1.3 llvm-test/SingleSource/UnitTests/Integer/switch.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/switch.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/switch.c Mon Jan 22 14:47:27 2007 @@ -1,20 +1,30 @@ -//===--- switch.c --- Test Cases for Bit Accurate Types -------------------===// +//===--- switch.c --- Test Cases for Bit Accurate Types -----------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for switch statement. The switch value is a // non-regular bitwidth. test(int3 c) function return the value of the // argument c. // -//===----------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> typedef unsigned int __attribute__ ((bitwidth(7))) int7; typedef unsigned int __attribute__ ((bitwidth(3))) int3; +<<<<<<< switch.c +======= const int7 zero = (int7)(1 << 8); // constant 0; static int3 seven = (int3)0xf; // constant 7; +>>>>>>> 1.2 + +const int7 zero = 0; // constant 0; +static int3 seven = 7; // constant 7; -int3 test(unsigned char c) +int3 test(int3 c) { switch(c){ Index: llvm-test/SingleSource/UnitTests/Integer/template.cpp diff -u llvm-test/SingleSource/UnitTests/Integer/template.cpp:1.3 llvm-test/SingleSource/UnitTests/Integer/template.cpp:1.4 --- llvm-test/SingleSource/UnitTests/Integer/template.cpp:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/template.cpp Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- template.cpp --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- template.cpp --- Test Cases for Bit Accurate Types -------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for template functions. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <iostream> Index: llvm-test/SingleSource/UnitTests/Integer/template2.cpp diff -u llvm-test/SingleSource/UnitTests/Integer/template2.cpp:1.2 llvm-test/SingleSource/UnitTests/Integer/template2.cpp:1.3 --- llvm-test/SingleSource/UnitTests/Integer/template2.cpp:1.2 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/template2.cpp Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- template2.cpp --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- template2.cpp --- Test Cases for Bit Accurate Types ------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for template classes. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> typedef int __attribute__ ((bitwidth(26))) int26; Index: llvm-test/SingleSource/UnitTests/Integer/template3.cpp diff -u llvm-test/SingleSource/UnitTests/Integer/template3.cpp:1.3 llvm-test/SingleSource/UnitTests/Integer/template3.cpp:1.4 --- llvm-test/SingleSource/UnitTests/Integer/template3.cpp:1.3 Sat Jan 20 13:35:27 2007 +++ llvm-test/SingleSource/UnitTests/Integer/template3.cpp Mon Jan 22 14:47:27 2007 @@ -1,11 +1,16 @@ -//===--- template3.cpp --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- template3.cpp --- Test Cases for Bit Accurate Types ------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for partial specialization. // //===------------------------------------------------------------------------===// #include <stdio.h> -using namespace std; + typedef int __attribute__ ((bitwidth(17))) int17; typedef int __attribute__ ((bitwidth(15))) int15; Index: llvm-test/SingleSource/UnitTests/Integer/union-init.c diff -u llvm-test/SingleSource/UnitTests/Integer/union-init.c:1.3 llvm-test/SingleSource/UnitTests/Integer/union-init.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/union-init.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/union-init.c Mon Jan 22 14:47:27 2007 @@ -1,9 +1,13 @@ -//===--- union-init.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- union-init.c --- Test Cases for Bit Accurate Types -------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for union initialization. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> Index: llvm-test/SingleSource/UnitTests/Integer/union-struct.c diff -u llvm-test/SingleSource/UnitTests/Integer/union-struct.c:1.3 llvm-test/SingleSource/UnitTests/Integer/union-struct.c:1.4 --- llvm-test/SingleSource/UnitTests/Integer/union-struct.c:1.3 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/union-struct.c Mon Jan 22 14:47:27 2007 @@ -1,10 +1,14 @@ -//===--- union-struct.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- union-struct.c --- Test Cases for Bit Accurate Types -----------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for struct with union inside. The purpose is to see // whether the size of the structure is correct. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> Index: llvm-test/SingleSource/UnitTests/Integer/union2.c diff -u llvm-test/SingleSource/UnitTests/Integer/union2.c:1.2 llvm-test/SingleSource/UnitTests/Integer/union2.c:1.3 --- llvm-test/SingleSource/UnitTests/Integer/union2.c:1.2 Fri Jan 19 16:54:01 2007 +++ llvm-test/SingleSource/UnitTests/Integer/union2.c Mon Jan 22 14:47:27 2007 @@ -1,10 +1,14 @@ -//===--- union2.c --- Test Cases for Bit Accurate Types -------------------------------===// +//===--- union2.c --- Test Cases for Bit Accurate Types -----------------===// +// +// This file was developed by Guoling han and donated to the LLVM research +// group and is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +//===-------------------------------------------------------------------===// // // This is a test for union type. By assigning values to different // fields, we can check whether the assignment is correctly performed. // -//===------------------------------------------------------------------------===// - +//===--------------------------------------------------------------------===// #include <stdio.h> typedef int __attribute__ ((bitwidth(9))) int9; typedef int __attribute__ ((bitwidth(31))) int31; _______________________________________________ llvm-commits mailing list llvm-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits