Assembly and Low-Level Language Fundamentals Questions

Programming and debugging at the instruction level. Covers reading and writing assembly for x86-64 and ARM (A32, Thumb, AArch64), including small hand-written routines, vector (SIMD) code and exclusive load/store atomics, registers, the stack and frame layout, prologues and epilogues, calling conventions and ABIs (System V, Microsoft x64, AAPCS), variadic calls, inline assembly and its constraints and clobbers, Cortex-M exception entry and context-switch code written in assembly, and how compilers translate and optimize source into machine code (optimization flags, inlining, tail calls, LTO, aliasing, strength reduction, virtual dispatch, memcpy lowering, stack spills). Also covers object files and linking as they affect generated code (ELF, PE/COFF and Mach-O, relocations, GOT and PLT, position-independent code, static linking, stack unwinding), the compiler backend ideas behind it (SSA, register allocation, instruction selection, peephole passes) and emitting machine code from a minimal JIT. On the debugging side: reading disassembly, using gdb and lldb for registers, frames, breakpoints and watchpoints, analyzing core dumps and stripped binaries with addr2line and build IDs, and diagnosing crashes from instruction-level state such as corrupted returns, stack smashing, ABI mismatches and optimizer-induced bugs. Debugging method in general, hardware probe tooling, malware analysis and exploit-mitigation design are covered elsewhere.

MediumTechnical
74 practiced

You have a snippet of assembly and a compiled binary. How would you work out which C function produced that snippet, and how does the approach change if the binary is stripped? Which tools would you reach for and what question does each answer?

EasyTechnical
74 practiced

Walk through the stages a C or C++ program goes through from source to a running ELF binary. At which stage is each of these decided: which symbols are visible in the final file, whether stack protection and position-independent code are in effect, and what a reviewer can still learn from a stripped binary?

HardTechnical
69 practiced

A bug appears only when a signal interrupts a syscall, and the handler returns into code compiled with -fomit-frame-pointer. At the assembly and register level, how would you inspect the signal context, stack frames, and saved state to determine whether the failure is in user code, libc, or the kernel boundary?

HardTechnical
73 practiced

A C application calls into a Rust or assembly library and fails only when the arguments are large or a variadic path is taken. What would you check at the register and stack level to confirm an ABI mismatch?

MediumTechnical
78 practiced

Why can function inlining make stack traces and source-level debugging misleading, and how would you use disassembly, debug info, and frame inspection to understand what really executed in a performance-critical or security-sensitive path?

Unlock Full Question Bank

Get access to all 15 Assembly and Low-Level Language Fundamentals interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.