⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 copyprop.s

📁 用Java实现的编译器。把源代码编译成SPARC汇编程序
💻 S
字号:
    ! SPARC assembly:     ! Automatically generated by ASM.SPARCGenerator.section	".data".GLOBALFIELD:.ARRAY_OUT_OF_BOUND:	.asciz "testcases/dataflow/copyprop.dcf:%d: runtime error: array out of bound; accessing: %d, array size: %d\n"	.align 4.DIVISION_ZERO:	.asciz "testcases/dataflow/copyprop.dcf:%d: runtime error: division to zero\n"	.align 4.CONTROL_FALLING_OFF:	.asciz "testcases/dataflow/copyprop.dcf:%s: runtime error: control falling off the end of the method: %s , missing a return value\n"	.align 4.section	".text"	.align 4	.global main	.globl mainmain:	sethi	%hi(.GLOBALFIELD), %g2	or	%g2, %lo(.GLOBALFIELD), %g2	save	%sp, -120, %sp	st	%g0, [%fp-4]	st	%g0, [%fp-8]	st	%g0, [%fp-12]	st	%g0, [%fp-16]	st	%g0, [%fp-20]	st	%g0, [%fp-24]	st	%g0, [%fp-28]	mov	8, %g3	sub	%sp, %g3, %sp	sethi	%hi(.CalloutArg1), %g1	or	%g1, %lo(.CalloutArg1), %g1	! Preparing parameter -> sp% + offset:  	st	%g1, [%sp+92]	! Preparing parameter -> Ro:  	ld	[%sp+92], %o0	call	printf,0	nop	mov	%o0, %l0	mov	8, %g3	add	%sp, %g3, %sp	mov	8, %g3	sub	%sp, %g3, %sp	sethi	%hi(.CalloutArg2), %g1	or	%g1, %lo(.CalloutArg2), %g1	! Preparing parameter -> sp% + offset:  	st	%g1, [%sp+92]	! Preparing parameter -> Ro:  	ld	[%sp+92], %o0	call	printf,0	nop	mov	%o0, %l0	mov	8, %g3	add	%sp, %g3, %sp	mov	8, %g3	sub	%sp, %g3, %sp	sethi	%hi(.CalloutArg3), %g1	or	%g1, %lo(.CalloutArg3), %g1	! Preparing parameter -> sp% + offset:  	st	%g1, [%sp+92]	! Preparing parameter -> Ro:  	ld	[%sp+92], %o0	call	printf,0	nop	mov	%o0, %l0	mov	8, %g3	add	%sp, %g3, %sp	! Move instruction for the int literal:  1	mov	1, %l0	!Location id store instruction for stmt location:   a = expression	st	%l0, [%fp-4]	! Move instruction for the int literal:  2	mov	2, %l0	!Location id store instruction for stmt location:   b = expression	st	%l0, [%fp-8]	! Move instruction for the int literal:  3	mov	3, %l0	!Location id store instruction for stmt location:   c = expression	st	%l0, [%fp-12]	! Load instruction for the location identifier:  a	ld	[%fp-4], %l0	! Load instruction for the location identifier:  b	ld	[%fp-8], %l1	add	%l0, %l1, %l2	!Location id store instruction for stmt location:   d = expression	st	%l2, [%fp-16]	! Load instruction for the location identifier:  d	ld	[%fp-16], %l0	!Location id store instruction for stmt location:   e = expression	st	%l0, [%fp-20]	! Load instruction for the location identifier:  d	ld	[%fp-16], %l0	!Location id store instruction for stmt location:   f = expression	st	%l0, [%fp-24]	mov	8, %g3	sub	%sp, %g3, %sp	sethi	%hi(.CalloutArg4), %g1	or	%g1, %lo(.CalloutArg4), %g1	! Preparing parameter -> sp% + offset:  	st	%g1, [%sp+92]	! Load instruction for the location identifier:  f	ld	[%fp-24], %l0	! Preparing parameter -> sp%+offset:  	st	%l0, [%sp+96]	! Preparing parameter -> Ro:  	ld	[%sp+92], %o0	! Preparing parameter -> Ro:  	ld	[%sp+96], %o1	call	printf,0	nop	mov	%o0, %l0	mov	8, %g3	add	%sp, %g3, %sp	! Load instruction for the location identifier:  c	ld	[%fp-12], %l0	!Location id store instruction for stmt location:   e = expression	st	%l0, [%fp-20]	! Load instruction for the location identifier:  c	ld	[%fp-12], %l0	! Move instruction for the int literal:  3	mov	3, %l1	add	%l0, %l1, %l2	!Location id store instruction for stmt location:   f = expression	st	%l2, [%fp-24]	! Load instruction for the location identifier:  b	ld	[%fp-8], %l0	!Location id store instruction for stmt location:   a = expression	st	%l0, [%fp-4]	! Load instruction for the location identifier:  c	ld	[%fp-12], %l0	! Move instruction for the int literal:  5	mov	5, %l1	cmp	%l0, %l1	bl	.True6	nop	mov	0, %l2	b	.End6	nop.True6:	mov	1, %l2.End6:	cmp	%g0, %l2	be	.False5	nop	! Load instruction for the location identifier:  c	ld	[%fp-12], %l0	! Load instruction for the location identifier:  c	ld	[%fp-12], %l1	add	%l0, %l1, %l2	!Location id store instruction for stmt location:   e = expression	st	%l2, [%fp-20]	! Load instruction for the location identifier:  b	ld	[%fp-8], %l0	!Location id store instruction for stmt location:   b = expression	st	%l0, [%fp-8]	b	.End5	nop.False5:.End5:	! Load instruction for the location identifier:  e	ld	[%fp-20], %l0	! Move instruction for the int literal:  3	mov	3, %l1	sub	%l0, %l1, %l2	!Location id store instruction for stmt location:   a = expression	st	%l2, [%fp-4]	mov	8, %g3	sub	%sp, %g3, %sp	sethi	%hi(.CalloutArg7), %g1	or	%g1, %lo(.CalloutArg7), %g1	! Preparing parameter -> sp% + offset:  	st	%g1, [%sp+92]	! Load instruction for the location identifier:  a	ld	[%fp-4], %l0	! Preparing parameter -> sp%+offset:  	st	%l0, [%sp+96]	! Preparing parameter -> Ro:  	ld	[%sp+92], %o0	! Preparing parameter -> Ro:  	ld	[%sp+96], %o1	call	printf,0	nop	mov	%o0, %l0	mov	8, %g3	add	%sp, %g3, %sp	mov	8, %g3	sub	%sp, %g3, %sp	sethi	%hi(.CalloutArg8), %g1	or	%g1, %lo(.CalloutArg8), %g1	! Preparing parameter -> sp% + offset:  	st	%g1, [%sp+92]	! Load instruction for the location identifier:  b	ld	[%fp-8], %l0	! Preparing parameter -> sp%+offset:  	st	%l0, [%sp+96]	! Preparing parameter -> Ro:  	ld	[%sp+92], %o0	! Preparing parameter -> Ro:  	ld	[%sp+96], %o1	call	printf,0	nop	mov	%o0, %l0	mov	8, %g3	add	%sp, %g3, %sp	mov	8, %g3	sub	%sp, %g3, %sp	sethi	%hi(.CalloutArg9), %g1	or	%g1, %lo(.CalloutArg9), %g1	! Preparing parameter -> sp% + offset:  	st	%g1, [%sp+92]	! Load instruction for the location identifier:  c	ld	[%fp-12], %l0	! Preparing parameter -> sp%+offset:  	st	%l0, [%sp+96]	! Preparing parameter -> Ro:  	ld	[%sp+92], %o0	! Preparing parameter -> Ro:  	ld	[%sp+96], %o1	call	printf,0	nop	mov	%o0, %l0	mov	8, %g3	add	%sp, %g3, %sp	mov	8, %g3	sub	%sp, %g3, %sp	sethi	%hi(.CalloutArg10), %g1	or	%g1, %lo(.CalloutArg10), %g1	! Preparing parameter -> sp% + offset:  	st	%g1, [%sp+92]	! Load instruction for the location identifier:  d	ld	[%fp-16], %l0	! Preparing parameter -> sp%+offset:  	st	%l0, [%sp+96]	! Preparing parameter -> Ro:  	ld	[%sp+92], %o0	! Preparing parameter -> Ro:  	ld	[%sp+96], %o1	call	printf,0	nop	mov	%o0, %l0	mov	8, %g3	add	%sp, %g3, %sp	mov	8, %g3	sub	%sp, %g3, %sp	sethi	%hi(.CalloutArg11), %g1	or	%g1, %lo(.CalloutArg11), %g1	! Preparing parameter -> sp% + offset:  	st	%g1, [%sp+92]	! Load instruction for the location identifier:  e	ld	[%fp-20], %l0	! Preparing parameter -> sp%+offset:  	st	%l0, [%sp+96]	! Preparing parameter -> Ro:  	ld	[%sp+92], %o0	! Preparing parameter -> Ro:  	ld	[%sp+96], %o1	call	printf,0	nop	mov	%o0, %l0	mov	8, %g3	add	%sp, %g3, %sp	mov	8, %g3	sub	%sp, %g3, %sp	sethi	%hi(.CalloutArg12), %g1	or	%g1, %lo(.CalloutArg12), %g1	! Preparing parameter -> sp% + offset:  	st	%g1, [%sp+92]	! Load instruction for the location identifier:  f	ld	[%fp-24], %l0	! Preparing parameter -> sp%+offset:  	st	%l0, [%sp+96]	! Preparing parameter -> Ro:  	ld	[%sp+92], %o0	! Preparing parameter -> Ro:  	ld	[%sp+96], %o1	call	printf,0	nop	mov	%o0, %l0	mov	8, %g3	add	%sp, %g3, %sp	!Return statement for method:	ret	restore	!Datasection.CalloutArg1:	.asciz "A? "	.align 8.CalloutArg2:	.asciz "B? "	.align 8.CalloutArg3:	.asciz "C? "	.align 8.CalloutArg4:	.asciz "f: %d  "	.align 8.CalloutArg7:	.asciz "a: %d  "	.align 8.CalloutArg8:	.asciz "b: %d  "	.align 8.CalloutArg9:	.asciz "c: %d  "	.align 8.CalloutArg10:	.asciz "d: %d  "	.align 8.CalloutArg11:	.asciz "e: %d  "	.align 8.CalloutArg12:	.asciz "f: %d\n\n"	.align 8.MDNAME_main:	.asciz "'main( )'"	.align 8.MDNAME_main_LINE_NO:	.asciz "41"	.align 8

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -