aboutsummaryrefslogtreecommitdiff
path: root/test/bitfield-assignment-sign-extend.qbe
blob: 3589d2f916e19fb166e217cb973ac602d2d6a4ff (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
export
function w $main() {
@start.1
@body.2
	%.1 =l add $s, 0
	%.2 =w shl 15, 0
	%.3 =w shl %.2, 28
	%.4 =w sar %.3, 28
	%.5 =w and %.2, 15
	%.6 =w loadw %.1
	%.7 =w and %.6, 18446744073709551600
	%.8 =w or %.5, %.7
	storew %.8, %.1
	%.9 =w neg 1
	%.10 =w cnew %.4, %.9
	ret %.10
}
export data $s = align 4 { z 4 }