Assembly Language Succinctly

This document was uploaded by one of our users. The uploader already confirmed that they had the permission to publish it. If you are author/publisher or own the copyright of this documents, please report to us by using this DMCA report form.

Simply click on the Download Book button.

Yes, Book downloads on Ebookily are 100% Free.

Sometimes the book is free on Amazon As well, so go ahead and hit "Search on Amazon"

Assembly language is as close to writing machine code as you can get without writing in pure hexadecimal. Since it is such a low-level language, it’s not practical in all cases, but should definitely be considered when you’re looking to maximize performance. With Assembly Language Succinctly by Chris Rose, you’ll learn how to write x64 assembly for modern CPUs, first by writing inline assembly for 32-bit applications, and then writing native assembly for C++ projects. You’ll learn the basics of memory spaces, data segments, CISC instructions, SIMD instructions, and much more. Whether you’re working with Intel, AMD, or VIA CPUs, you’ll find this book a valuable starting point since many of the instructions are shared between processors.

Author(s): Chris Rose
Publisher: Syncfusion
Year: 2013

Language: English
Pages: 132
Tags: Информатика и вычислительная техника;Информатика (программирование);Программирование на ASSEMBLER;

The Story behind the Succinctly Series of Books......Page 10
About the Author......Page 12
Why Learn Assembly?......Page 13
Intended Audience......Page 14
Inline Assembly in 32-Bit Applications......Page 15
Native Assembly Files in C++......Page 16
Additional Steps for x64......Page 20
64-bit Code Example......Page 24
Skeleton of an x64 Assembly File......Page 26
Skeleton of an x32 Assembly File......Page 27
Comments......Page 28
Segments......Page 29
Anonymous Labels......Page 30
Data Types......Page 31
Little and Big Endian......Page 32
Two’s and One’s Complement......Page 33
Chapter 3 Memory Spaces......Page 34
16-Bit Register Set......Page 35
32-Bit Register Set......Page 37
64-bit Register Set......Page 39
Immediate Addressing Mode......Page 41
Memory Addressing Mode......Page 42
Scalar Data......Page 45
Duplicate Syntax for Larger Arrays......Page 46
Getting Information about an Array......Page 47
Defining Strings......Page 48
Structures and Unions......Page 49
Structures of Structures......Page 52
Records......Page 53
Constants Using Equates To......Page 55
Macros......Page 56
Scratch versus Non-Scratch Registers......Page 59
Passing Parameters......Page 61
Shadow Space......Page 62
Parameter Format......Page 67
Flags Register......Page 68
Lock Prefix......Page 69
Move......Page 70
Conditional Moves......Page 71
Nontemporal Move......Page 72
Exchange......Page 73
Sign Extend AL, AX, and EAX......Page 74
Pop Data from Stack......Page 75
Load Effective Address......Page 76
Byte Swap......Page 77
Add with Carry and Subtract with Borrow......Page 78
Increment and Decrement......Page 79
Multiply......Page 80
Signed and Unsigned Division......Page 82
Boolean And, Or, Xor......Page 83
Test Bits......Page 84
Rotate Left and Right......Page 85
Bit Test......Page 86
Conditional Byte Set......Page 87
Set and Clear the Carry or Direction Flags......Page 88
Jumps......Page 89
Load String......Page 90
Store String......Page 91
Scan String......Page 92
Compare String......Page 93
Read Time Stamp Counter......Page 94
Loop......Page 95
CPUID......Page 96
Chapter 8 SIMD Instruction Sets......Page 100
Saturating Arithmetic versus Wraparound Arithmetic......Page 101
MMX......Page 102
Referencing Memory......Page 103
Move Dword......Page 104
Shifting Bits......Page 105
Arithmetic Instructions......Page 106
Comparisons......Page 108
Creating the Remaining Comparison Operators......Page 109
Packing......Page 110
Unpacking......Page 111
Introduction......Page 113
AVX......Page 114
Move Unaligned Packed Doubles/Singles......Page 115
Adding Floating Point Values......Page 116
Subtracting Floating Point Values......Page 117
Dividing Floating Point Values......Page 118
Multiplying Floating Point Values......Page 119
Square Root of Floating Point Values......Page 120
Reciprocal of Single-Precision Floats......Page 121
AND NOT Packed Doubles/Singles......Page 122
OR Packed Doubles/Singles......Page 123
Comparing Packed Doubles and Singles......Page 124
Comparing and Setting rFlags......Page 125
Conversion Instructions......Page 126
Selecting the Rounding Function......Page 128
Conclusion......Page 130
Recommended Reading......Page 131