python语言写汇编器_汇编语言程序作业代写代做、代做汇编语言作业、代做留学生汇编作业代写Python编程|代做留学生Processing...

(CSCI 365) Project Seven Bitwise Multiplication

Objectives:

1.Implement Bitwise Multiplication algorithm

2.Apply loop

3.Write user defined procedure

4.Use user defined procedure

5.Apply Irvine32.inc library

Problem Description:

Write a procedure named BitwiseMultiply that multiplies any unsinged 32-bit integer by EAX, using only sifting and addition. Pass the integer to the procedure in the EBX register and return the product in the EXA register. Write a short test program that calls the procedure and displays the product (We will assume that the product is never larger than 32 bits). This is a fairly challenging program to write. One possible approach is to use a loop to shift the multiplier to the right, keeping track of the number of shifts that occur before the Carry flag is set. The resulting shift count can then be applied to the SHL instruction, using the multiplicand as the destination operand. Then the same process must be repeated until you find the last 1 bit in the multiplier (Refer to Programming Exercise #7 on page 285)

Sample Run:

After user hits any key, the program exits.

Due Date:

Turn in YourNameProj7.asm via Blackboard. Due date will be announced on Blackboard

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
PeachPy 是一个用于编高性能汇编内核的 Python 框架,可在汇编中编模块。 它自动化了一些细节,并允许使用 Python 生成重复的汇编代码序列。PeachPy 旨在简化编优化的汇编内核,同时保留传统的汇编所有优化机会。一些特性:用于 Windows,Unix 和 Golang 程序集的通用汇编语法.PeachPy 可以直接生成 ELF,MS COFF 和 Mach-O 对象文件以及 Golang 工具链的汇编列表自动适应不同的调用约定和 ABIs用于不同平台的功能可以从汇编相同的源生成支持 Microsoft x64 ABI, System V x86-64 ABI (Linux 和 OS X), Linux x32 ABI, Native Client x86-64 SFI ABI, Golang AMD64 ABI, Golang AMD64p32 ABI自动分配寄存器PeachPy 是灵活的,而且允许在同一代码中混合自动分配寄存器和硬编码寄存器汇编编程中常规任务的自动化:函数 prolog 和 epilog 由 PeachPy 生成数据常量的重复数据删除 (e.g. Constant.float32x4(1.0))分析在函数中使用的 ISA 扩展支持 x86-64 指令,最高可达 AVX-512 和 SHA包含 3dnow! , XOP, FMA3, FMA4, TBM 和 BMI2.不包括 x87 FPU 和大多数系统指令使用自动生成的测试 auto-generated tests 进行严格测试,以生成与 binutils 相同的操作码自动生成元数据文件具有模块依赖性的Makefile (-MMD 和-MF 选项)C 头文件生成的函数JSON 格式的函数元数据基于 Python 的元编程和代码生成多个指令流的复用(有助于软件流水线)兼容 Python 2 和 Python 3,CPython 和 PyPy在线 DEMO: PeachPy.IO 标签:PeachPy

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值