search for: mystru

Displaying 3 results from an estimated 3 matches for "mystru".

2002 Sep 17
3
[LLVMdev] questions
...ype()? If I use that, I will get a PointerType, how can I use it? 2. Another question is that since we do the scalar replacement on each function. If the program look like this. struct s { int a; float b; } fun1( struct s *ps) { ps->a = 1; ps->b = 2; } main( ) { struct s mystru; fun1( &mystru ); } When we process the function 'fun1', should we change fun1 to something like fun1( int *a, float *b ) then change fun1(&mystru) in main to something like fun1( &mystru.a, &mystru.b)? Thanks, xiaodong
2002 Sep 17
0
[LLVMdev] questions
...Work with ST... and it'll work. } 2. Another question is that since we do the scalar replacement } on each function. If the program look like this. } } struct s { } int a; } float b; } } } fun1( struct s *ps) { } ps->a = 1; } ps->b = 2; } } } main( ) } { } struct s mystru; } } fun1( &mystru ); } } } } When we process the function 'fun1', should we change fun1 to } something like } fun1( int *a, float *b ) } then change fun1(&mystru) in main to something like } fun1( &mystru.a, &mystru.b)? } I assume that, since "mystru" isn'...
2002 Sep 17
0
[LLVMdev] questions
...f Type that tells you what type a value is (okay, that's annoyingly circular, I hope it makes sense). getElementType() is a member of the PointerType class that returns the type the pointer wraps. So on an 'int*', it will return 'int'. > >> I assume that, since "mystru" isn't being used as specified > in rules > >> U1-U3, that we shouldn't have to handle it... > >> But I could be wrong... > Does our code need to actually read throught the code to see > if every usage of the pointer is in U1-U3? If we need to do > that, h...