nasm

Move 32bit register into a 8 bit register

你说的曾经没有我的故事 提交于 2020-08-20 12:42:14
问题 Im trying to move edx into al but i get this error lib/io/print.asm:50: error: invalid combination of opcode and operands this is the code mov edx, 0x41 mov al, edx thanks in advance 回答1: The problem is the second line: mov al, edx The edx register is 32-bits, but al is 8-bit, so you can't directly move one into the other. If you want to move the low 8 bits of edx into dl , do this: mov al, dl Or perhaps you want to move all of edx into eax , like this: mov eax, edx The difference is the

Move 32bit register into a 8 bit register

醉酒当歌 提交于 2020-08-20 12:41:12
问题 Im trying to move edx into al but i get this error lib/io/print.asm:50: error: invalid combination of opcode and operands this is the code mov edx, 0x41 mov al, edx thanks in advance 回答1: The problem is the second line: mov al, edx The edx register is 32-bits, but al is 8-bit, so you can't directly move one into the other. If you want to move the low 8 bits of edx into dl , do this: mov al, dl Or perhaps you want to move all of edx into eax , like this: mov eax, edx The difference is the

nasm system calls Linux

微笑、不失礼 提交于 2020-08-19 09:10:52
问题 I have got a question about linux x86 system calls in assembly. When I am creating a new assembly program with nasm on linux, I'd like to know which system calls I have to use for doing a specific task (for example reading a file, writing output, or simple exiting...). I know some syscall because I've read them on some examples taken around internet (such as eax=0, ebx=1 int 0x80 exit with return value of 1), but nothing more... How could I know if there are other arguments for exit syscall?

OpenSSL 3.0 版本已经发布VS2019编译源码教程

心已入冬 提交于 2020-08-18 20:48:10
1 OpenSSL 3.0版本在2020年五月发布  OpenSSL3.0 在2020年5月发布了第一个版本,随即在六月份又发布了一些alpha版本,版本修正了一些bug,增加了一些协议支持,继续支持国密sm2 ,sm3 ,sm4(从1.1.1版本开始支持)。   3.0版本完全兼容1.1.1版本接口,但低级别的MD2, MD4, MD5, MDC2,SHA1, SHA224, SHA256, SHA384, SHA512,AES,DES,ECDH,DSA,ECDSA,RSA接口都会被警告将要被弃用。但文档中没有提及要用什么接口替换,估计是全部用EVP接口替换,我在项目中基本都替换为了EVP接口。  2 OpenSSL 3.0版本使用VS2019编译过程 2.1 OpenSSL3.0 源码下载 源码可以到官方网站或者直接使用git进行下载 下载地址 ffmpeg.vip 或者使用git下载版本库上最新源码 git clone git://git.openssl.org/openssl.git 2.2 依赖工具安装 安装 perl 脚本解释器 下载 http://openssl.vip/download 安装 nasm 汇编器 下载地址 http://openssl.vip/download 默认会安装到用户目录 C:\Users\用户名\AppData\Local\bin