* Manually rename BasicBlock to BlockPredecessor BasicBlock is a pair of (Ebb, Inst) that is used to represent the basic block subcomponent of an Ebb that is a predecessor to an Ebb. Eventually we will be able to remove this struct, but for now it makes sense to give it a non-conflicting name so that we can start to transition Ebb to represent a basic block. I have not updated any comments that refer to BasicBlock, as eventually we will remove BlockPredecessor and replace with Block, which is a basic block, so the comments will become correct. * Manually rename SSABuilder block types to avoid conflict SSABuilder has its own Block and BlockData types. These along with associated identifier will cause conflicts in a later commit, so they are renamed to be more verbose here. * Automatically rename 'Ebb' to 'Block' in *.rs * Automatically rename 'EBB' to 'block' in *.rs * Automatically rename 'ebb' to 'block' in *.rs * Automatically rename 'extended basic block' to 'basic block' in *.rs * Automatically rename 'an basic block' to 'a basic block' in *.rs * Manually update comment for `Block` `Block`'s wikipedia article required an update. * Automatically rename 'an `Block`' to 'a `Block`' in *.rs * Automatically rename 'extended_basic_block' to 'basic_block' in *.rs * Automatically rename 'ebb' to 'block' in *.clif * Manually rename clif constant that contains 'ebb' as substring to avoid conflict * Automatically rename filecheck uses of 'EBB' to 'BB' 'regex: EBB' -> 'regex: BB' '$EBB' -> '$BB' * Automatically rename 'EBB' 'Ebb' to 'block' in *.clif * Automatically rename 'an block' to 'a block' in *.clif * Fix broken testcase when function name length increases Test function names are limited to 16 characters. This causes the new longer name to be truncated and fail a filecheck test. An outdated comment was also fixed.
174 lines
4.0 KiB
Plaintext
174 lines
4.0 KiB
Plaintext
test compile
|
|
set opt_level=speed
|
|
set enable_pinned_reg=true
|
|
target x86_64 haswell
|
|
|
|
;; Test for the issue #1123; https://github.com/bytecodealliance/cranelift/issues/1123
|
|
|
|
function u0:0(i32, i32, i32, i64 vmctx) -> i64 uext system_v {
|
|
block0(v0: i32, v1: i32, v2: i32, v3: i64):
|
|
v351 = iconst.i32 0x4de9_bd37
|
|
v31 = iconst.i32 -23
|
|
v35 = iconst.i32 0
|
|
v36 = iconst.i32 -31
|
|
v357 = iconst.i32 0x4de9_bd37
|
|
v530, v358 = x86_smulx v36, v357
|
|
v359 = isub v358, v36
|
|
v360 = sshr_imm v359, 4
|
|
v361 = iconst.i32 0
|
|
v362 = iadd v360, v361
|
|
v38 -> v362
|
|
v532 = sshr_imm v35, 31
|
|
v533, v534 = x86_sdivmodx v35, v532, v362
|
|
v39 -> v533
|
|
v53 = iconst.i32 0
|
|
v547 = ifcmp_imm v53, -1
|
|
trapif ne v547, user0
|
|
jump block30
|
|
|
|
block30:
|
|
v75 = iconst.i32 0
|
|
v581 = ifcmp_imm v75, -1
|
|
trapif ne v581, user0
|
|
jump block42
|
|
|
|
block42:
|
|
v136 = iconst.i32 0
|
|
v691 = ifcmp_imm v136, -1
|
|
trapif ne v691, user0
|
|
jump block81
|
|
|
|
block81:
|
|
v158 = iconst.i32 0
|
|
v725 = ifcmp_imm v158, -1
|
|
trapif ne v725, user0
|
|
jump block93
|
|
|
|
block93:
|
|
v760 = iconst.i32 0
|
|
jump block106(v760)
|
|
|
|
block106(v175: i32):
|
|
v179 = iconst.i32 0
|
|
v180 = icmp_imm eq v179, 0
|
|
v183 = iconst.i32 0
|
|
v766 = ifcmp_imm v183, -1
|
|
trapif ne v766, user0
|
|
jump block108
|
|
|
|
block108:
|
|
v771 = iconst.i32 0
|
|
jump block109(v771)
|
|
|
|
block109(v184: i32):
|
|
v785 = iconst.i32 0
|
|
v193 -> v785
|
|
v791 = ifcmp_imm v193, -1
|
|
trapif ne v791, user0
|
|
jump block117
|
|
|
|
block117:
|
|
v796 = iconst.i32 0
|
|
jump block118(v796)
|
|
|
|
block118(v194: i32):
|
|
v203 = iconst.i32 -63
|
|
v809 = iconst.i32 0
|
|
v207 -> v809
|
|
v815 = ifcmp_imm v207, -1
|
|
trapif ne v815, user0
|
|
jump block126
|
|
|
|
block126:
|
|
v209 = iconst.i32 0
|
|
v823 = ifcmp_imm v209, -1
|
|
trapif ne v823, user0
|
|
jump block129
|
|
|
|
block129:
|
|
v213 = iconst.i32 -23
|
|
v214 = iconst.i32 -19
|
|
v215 = icmp_imm eq v214, 0
|
|
v216 = bint.i32 v215
|
|
v217 = popcnt v216
|
|
v435 = iconst.i32 0x7df7_df7d
|
|
v831, v436 = x86_smulx v217, v435
|
|
v437 = isub v436, v217
|
|
v438 = sshr_imm v437, 5
|
|
v439 = ushr_imm v438, 31
|
|
v440 = iadd v438, v439
|
|
v219 -> v440
|
|
v220 = rotr v213, v440
|
|
v229 = iconst.i32 0
|
|
v841 = iconst.i32 0
|
|
v842, v843 = x86_sdivmodx v194, v841, v229
|
|
v230 -> v842
|
|
v849 = iconst.i32 0
|
|
v850, v851 = x86_sdivmodx v184, v849, v230
|
|
v231 -> v850
|
|
v232 = iconst.i32 0
|
|
v857 = iconst.i32 0
|
|
v858, v859 = x86_sdivmodx v175, v857, v232
|
|
v233 -> v858
|
|
v915 = iconst.i32 0
|
|
jump block163(v915)
|
|
|
|
block163(v253: i32):
|
|
v255 = iconst.i32 0
|
|
v256 = iconst.i32 -23
|
|
v257 = iconst.i32 -19
|
|
v258 = icmp_imm eq v257, 0
|
|
v259 = bint.i32 v258
|
|
v260 = popcnt v259
|
|
v447 = iconst.i32 0x7df7_df7d
|
|
v921, v448 = x86_smulx v260, v447
|
|
v449 = isub v448, v260
|
|
v450 = sshr_imm v449, 5
|
|
v451 = ushr_imm v450, 31
|
|
v452 = iadd v450, v451
|
|
v262 -> v452
|
|
v263 = rotr v256, v452
|
|
v264 = popcnt v263
|
|
v265 = popcnt v264
|
|
v266 = popcnt v265
|
|
v267 = rotr v255, v266
|
|
v268 = popcnt v267
|
|
v923 = iconst.i32 0
|
|
v924, v925 = x86_sdivmodx v253, v923, v268
|
|
v269 -> v924
|
|
v276 = iconst.i32 0
|
|
v277 = iconst.i32 -63
|
|
v278 = popcnt v277
|
|
v947 = iconst.i32 0
|
|
v948, v949 = x86_sdivmodx v276, v947, v278
|
|
v279 -> v948
|
|
v309 = iconst.i32 0
|
|
v310 = iconst.i32 0
|
|
v311 = iconst.i32 0
|
|
v312 = icmp_imm eq v311, 0
|
|
v313 = bint.i32 v312
|
|
v314 = rotr v310, v313
|
|
v315 = iconst.i32 -31
|
|
v464 = iconst.i32 0
|
|
v1020, v465 = x86_smulx v315, v464
|
|
v466 = isub v465, v315
|
|
v467 = sshr_imm v466, 4
|
|
v468 = iconst.i32 0
|
|
v469 = iadd v467, v468
|
|
v317 -> v469
|
|
v1022 = iconst.i32 0
|
|
v1023, v1024 = x86_sdivmodx v314, v1022, v469
|
|
v318 -> v1023
|
|
v320 = iconst.i32 0
|
|
v321 = iconst.i32 -19
|
|
v322 = popcnt v321
|
|
v1030 = iconst.i32 0
|
|
v1031, v1032 = x86_sdivmodx v320, v1030, v322
|
|
v323 -> v1031
|
|
v1047 = iconst.i32 0
|
|
v325 -> v1047
|
|
v1054 = sshr_imm v309, 31
|
|
v1055, v1056 = x86_sdivmodx v309, v1054, v325
|
|
trap user0
|
|
}
|