Convert DEV C code to SPARC assembly
$10-30 USD
着払い
Hello,
I want to convert my C program to assembly language.
I know the gcc compiler which converts the C to .s file but I dont want that.
I tried the GCC convert but it converts it to 8086 I want it to convert to SPARC assembly
Please see the attached file
Please contact me ASAP, i can give some bonus.
this is an example of whole to clear and how it should look
.begin
! Example of setting bit 12. Number bits from 1 to 32
! Set bit 1 in %r2
or %r0, 1, %r2
! Set %r3 to 12
or %r0, 12, %r3
! subtract 1 from %r3
sub %r3, 1, %r3
! shift %r2 left 11 places, causing bit 12 to be set
sll %r2, %r3, %r2
! or register 2 with register 1, and store into register 1, setting bit 12
or %r2, %r1, %r1
! Example of clearing bit 12. Number bits from 1 to 32
! Set bit 1 in %r2
or %r0, 1, %r2
! Set %r3 to 12
or %r0, 12, %r3
! subtract 1 from %r3
sub %r3, 1, %r3
! shift %r2 left 11 places, causing bit 12 to be set
sll %r2, %r3, %r2
! Invert the bits in %r2 using bitwise XOR with 0xFFFFFFFF
xor %r2, 0xffffffff, %r2
! and register 2 with register 1, and store into register 1, clearing bit 12
and %r2, %r1, %r1
! Example of inverting (flipping) all bits in register %r1
xor %r1, 0xffffffff, %r1
! Example of determining whether bit 12 is set:
! Set bit 1 in %r2
or %r0, 1, %r2
! Set %r3 to 12
or %r0, 12, %r3
! subtract 1 from %r3
sub %r3, 1, %r3
! shift %r2 left 11 places, causing bit 12 to be set
sll %r2, %r3, %r2
! Compare %r2 to %r1; returns non-zero of the bit is set
andcc %r2, %r1, %r0
! If the and has a bit set, then the result is not equal to zero.
bne isset
! Bit is not set
! Your instructions here
ba end
isset:
! Bit is set
! Your instructions here
end:
halt
.end
プロジェクトID: #9039941
プロジェクトについて
アワード:
I have been developing c, c++, asm programs for 10 years. So I think I can do it so that you satisfy. I am looking forward to being hired by you. I hope to meet you later! I'll do my best to do it. Please a もっと