// Pointer-handling
setAction({G_FRAME_INDEX, p0}, Legal);
+ setAction({G_GLOBAL_VALUE, p0}, Legal);
setAction({G_PTRTOINT, 0, s64}, Legal);
setAction({G_PTRTOINT, 1, p0}, Legal);
entry:
ret void
}
+ @var = global i8 0
+ define i8* @test_global() { ret i8* undef }
...
---
%1(s64) = G_FCONSTANT double 2.0
%2(s16) = G_FCONSTANT half 0.0
...
+
+---
+name: test_global
+registers:
+ - { id: 0, class: _ }
+body: |
+ bb.0:
+ ; CHECK-LABEL: name: test_global
+ ; CHECK: %0(p0) = G_GLOBAL_VALUE @var
+
+ %0(p0) = G_GLOBAL_VALUE @var
+...