YASM x86-64 Assembly Functions Tutorial - Integers, Floats, Pointers, ABI, C++ Interoperability
Quick but complete guide to writing proper functions in YASM x86-64 assembly on Linux. See how to pass integers, pointers & floats, return values, follow the ABI, disable C++ name mangling with extern "C", and call back and forth between C++ and assembly in a real working example. Great for people moving from NASM/GAS or trying to mix assembly with higher-level code. 00:00 Introduction and Video Overview 00:28 What Are Functions in Programming 00:56 Why Functions Are Harder in Assembly 01:24 Topics Covered in This Video 01:59 About the Makefile and Prerequisites 02:28 Hybrid C++ and Assembly Program Plan 03:01 Using extern "C" to Disable Name Mangling 04:03 Main Driver Function in C++ 05:00 Adding a Callable C++ Function for Assembly 05:42 Explaining extern "C" Placement 06:16 Assembly File Skeleton and Data Section 06:41 Creating Null-Terminated Strings 07:49 Section .text and External Symbols 08:52 Declaring my_cpp_function as extern 09:20 Defining my_assembly_function 09:40 Labels vs Real Functions 10:31 The call Instruction and Return Address 11:16 Why Jumping Instead of Calling Crashes 11:47 Global Directive for Exporting Functions 12:32 Basic Function Structure 13:20 Implementing my_assembly_function Prologue 14:50 Receiving Arguments in ABI Registers 16:30 Printing Received Integer Arguments 18:10 Handling Pointer Arguments (C Strings) 19:40 Passing Floating-Point Arguments in XMM 21:15 Printing Floats from Assembly 23:00 Calling Back to C++ Function 25:40 Preparing Arguments for my_cpp_function 27:20 Loading XMM0 and XMM1 for Floats 29:10 Making the Call to C++ Function 30:50 Receiving Double Return Value in XMM0 32:30 Saving Returned Float to Memory 34:10 Printing the Returned Value 36:00 Final Messages and Program Flow 38:20 Fixing String Pointer Crash Issue 40:00 Correcting Argument Loading 42:10 Passing String Owned by Assembly 44:00 Observing Successful Output 45:47 Saving and Restoring XMM0 Safely 47:14 Printing Final Returned Float 48:32 Importance of Following the ABI 50:29 Summary of Covered Topics 51:03 Closing Remarks and Call to Subscribe =-=-=-=-=-=-=-=-= Thanks for watching! Find us on other social media here: https://www.NeuralLantern.com/social Twitter / X: https://x.com/NeuralLantern Rumble: https://rumble.com/c/c-3696939 BitChute: https://www.bitchute.com/channel/pg1P... Daily Motion: https://www.dailymotion.com/neurallan... Minds: https://www.minds.com/neurallantern/ Odysee: https://odysee.com/@NeuralLantern:5 Please show your support! Buy me a coffee: https://ko-fi.com/neurallantern Subscribe + Sharing on Social Media Leave a comment or suggestion Subscribe to the Blog: https://www.NeuralLantern.com Watch the main "pinned" video of this channel for offers and extras

x86-64 Assembly: Local Variables, Stack Frames & Alignment Explained

The Call Stack Explained: Call Frames, Return Addresses, Local Variables

Data-Oriented Demo: SOA, composition

How Your Code Really Controls Hardware

Master CGDB: Boost Your Debugging with GDB's Curses Interface in Terminal

Billionaire's WARNING: I'm SELLING. The Crash Is Already Here!

Why Aliens Would NEVER Invade Africa

248 DIOS TE DICE HOY: NADA ES IMPOSIBLE PARA MÍ | CONFÍA EN DIOS

ASMR Addictive Fast Tapping Collection For Deep Sleep & Anxiety Relief (No Talking) — 2.5 Hours

The basics of BASIC, the programming language of the 1980s.

How Huawei Just Built an Impossible Chip

Keynote: After the AI Hype – What’s Real, and What’s Next - Richard Campbell - 2026
![PINK & ORANGE GRADIENT IN HD [3 HOURS]](https://i.ytimg.com/vi/6ih8zppfQSQ/hqdefault.jpg?sqp=-oaymwE9CNACELwBSFryq4qpAy8IARUAAAAAGAElAADIQj0AgKJDeAHwAQH4Af4JgALQBYoCDAgAEAEYfyAsKBMwDw==&rs=AOn4CLDvw6mQM98bfl572zfE7r4GdUG8dg)
PINK & ORANGE GRADIENT IN HD [3 HOURS]

Implement strlen for Null-Terminated Strings in x86-64 Assembly (YASM)

x86-64 Assembly Pointers & Dereferencing Explained - Hybrid C++/YASM Example

How I Made A C64 Laptop From Scratch - The Portable 64 (Emulation)

Professor Jiang: World War 3 Is About To Begin, Let Me Explain!

No Celebrity Has ZERO Filter Like Harrison Ford _ and It’s HILARIOUS!

Conan O’Brien Mocks Trump At Harvard Commencement | Crowd Erupts During Viral Speech

