mirror of
https://github.com/danog/ir.git
synced 2024-11-26 20:34:53 +01:00
53 lines
817 B
Plaintext
53 lines
817 B
Plaintext
|
--TEST--
|
||
|
012: SCCP with long multislot instructions
|
||
|
--ARGS--
|
||
|
--save --dump-after-gcm
|
||
|
--CODE--
|
||
|
{
|
||
|
uintptr_t c_1 = 0;
|
||
|
bool c_2 = 0;
|
||
|
bool c_3 = 1;
|
||
|
int32_t c_4 = 1;
|
||
|
int32_t c_5 = 2;
|
||
|
int32_t c_6 = 3;
|
||
|
int32_t c_7 = 4;
|
||
|
l_1 = START(l_15);
|
||
|
l_2 = SWITCH(l_1, c_7);
|
||
|
l_3 = CASE_VAL(l_2, c_4);
|
||
|
l_4 = END(l_3);
|
||
|
l_5 = CASE_VAL(l_2, c_5);
|
||
|
l_6 = END(l_5);
|
||
|
l_7 = CASE_VAL(l_2, c_6);
|
||
|
l_8 = END(l_7);
|
||
|
l_9 = CASE_DEFAULT(l_2);
|
||
|
l_10 = END(l_9);
|
||
|
l_11 = MERGE/4(l_4, l_6, l_8, l_10);
|
||
|
int32_t d_13 = PHI/4(l_11, c_4, c_5, c_6, c_7);
|
||
|
l_15 = RETURN(l_11, d_13);
|
||
|
}
|
||
|
--EXPECT--
|
||
|
{
|
||
|
uintptr_t c_1 = 0;
|
||
|
bool c_2 = 0;
|
||
|
bool c_3 = 1;
|
||
|
int32_t c_4 = 1;
|
||
|
int32_t c_5 = 2;
|
||
|
int32_t c_6 = 3;
|
||
|
int32_t c_7 = 4;
|
||
|
l_1 = START(l_15);
|
||
|
NOP;
|
||
|
NOP;
|
||
|
NOP;
|
||
|
NOP;
|
||
|
NOP;
|
||
|
NOP;
|
||
|
NOP;
|
||
|
NOP;
|
||
|
NOP;
|
||
|
NOP;
|
||
|
NOP;
|
||
|
NOP;
|
||
|
NOP;
|
||
|
l_15 = RETURN(l_1, c_7);
|
||
|
}
|