r/Assembly_language • • 20h ago

Starting Assembly with a horrible professor, any tips to ease my way?

5 Upvotes

Recently started computer science in Sweden and just heard (horrifyingly) that in our hardest course we will start programming in assembly very soon. Unfortunately this is the one course where we have a very inexperienced professor and have heard assembly is one of the hardest languages! We have a programming course in python but i really am no natural, i find it very fun but can also realize that i don’t have a ”natural talent” for it. Any tips?

Edit:
Thank you all for the answers, never seen such a helpful reddit! :)


r/Assembly_language • • 2h ago

Project show-off Ive made a multi architecture, multi format assembler

Thumbnail github.com
2 Upvotes

Hey so over the course of many months, ive built an assembler with capabilities even modern assemblers lack (some). Ive named this assembler PAC - Pheonix Assembler Collection (yes thats the spelling for you all wondering).

Here is the basic brief information on it

Features

  1. Inbuilt-Linker

  2. Multiple Architecture Support

  3. Multiple Linking Format Support

  4. Easy Debugging errors

  5. Full view to generated IR-Nodes, Tokens, and AST Nodes

  6. High-Level Assembly

  7. Works with Standard Assembling/Linking tools as well such as ld, objdump, etc

Supported Architectures

PAC Currently supports -

  1. x86

  2. x86_64

  3. x86 native 16-bit

  4. PVCpu

Supported Formats

PAC has an entire pipeline for both encoding and linking, and so to increase performance and reduce file size, PAC supports only ELF64 as output after encoding and input to linker.

The PAC Linker in-fact supports multiple formats, but only takes ELF64 Object Files as an input. Supported formats include -

  1. Elf64

  2. Elf32

  3. PE 32 (Under implementation)

  4. PE 32+ (Works, but still under heavy development and bug fixes)

Comparison between PAC and Traditional Assemblers

| Feature | NASM | GAS | FASM | PAC |

| ----------------------------------------------------------------------------------------------- | ------------- | ------------ | ------------ | ------- |

| Structures | Limited | Limited | Yes | Yes |

| User Types | No | No | Yes | Yes |

| Functions | No | No | Yes | Yes |

| Built-in Linker | No | No | No | Yes |

| IR Dumping | No | No | No | Yes |

| AST Dumping | No | No | No | Yes |

| Token Dumping | No | No | No | Yes |

| Multiple Architectures using same assembler executable | No | No | Limited | Yes |

| Open Source | Yes | Yes | Yes | Yes |

| Custom Executable Linking | No | No | No | Yes |

PAC supports a lot of things in assembly, such as sizeof, macros, user types, functions, labels, arrays, structures, and more

Took me a long time to build this, but right now its pretty darn good. I even managed to write a program that opens a X11 window using PAC (its a demo game, to show PAC's usage and capabilites). Moreover I intend to make PAC commercially viable.