Jump to main content
MPLAB XC8 C Compiler User’s Guide for PIC MCU
MPLAB XC8 C Compiler User’s Guide for PIC MCU
  1. Home
  2. 3 How Tos
  3. 3.3 Writing Source Code
  4. 3.3.7 Assembly Code

  • Notice to Development Tools Customers
  • 1 Preface
  • 2 Compiler Overview
  • 3 How Tos
    • 3.1 Installing and Activating the Compiler
    • 3.2 Invoking the Compiler
    • 3.3 Writing Source Code
      • 3.3.1 C Language Specifics
      • 3.3.2 Device-Specific Features
      • 3.3.3 Memory Allocation
      • 3.3.4 Variables
      • 3.3.5 Functions
      • 3.3.6 Interrupts
      • 3.3.7 Assembly Code
        • 3.3.7.1 How Should I Combine Assembly And C Code?
        • 3.3.7.2 What Do I Need Other Than Instructions In An Assembly Source File?
        • 3.3.7.3 How Do I Access C Objects From Assembly Code?
        • 3.3.7.4 How Can I Access SFRs From Within Assembly Code?
        • 3.3.7.5 What Things Must I Manage When Writing Assembly Code?
    • 3.4 Getting My Application To Do What I Want
    • 3.5 Understanding the Compilation Process
    • 3.6 Fixing Code That Does Not Work
  • 4 Command-line Driver
  • 5 C Language Features
  • 6 Macro Assembler
  • 7 Linker
  • 8 Utilities
  • 9 Library Functions
  • 10 Error and Warning Messages
  • 11 Implementation-Defined Behavior
  • 12 Document Revision History
  • Microchip Information

3.3.7 Assembly Code

This section examines questions that arise when writing assembly code as part of a C project.

  • How Should I Combine Assembly and C Code?
  • What Do I Need Other than Instructions in an Assembly Source File?
  • How Do I Access C Objects from Assembly Code?
  • How Can I Access SFRs from Within Assembly Code?
  • What Things Must I Manage When Writing Assembly Code?

About

Company
Careers
Contact Us
Media Center
Investor Relations
Corporate Responsibility

Support

Microchip Forums
AVR Freaks
Design Help
Technical Support
Export Control Data
PCNs

Quick Links

microchipDIRECT.com
Microchip University
myMicrochip
Blogs
Reference Designs
Parametric Search
Microchip Logo

Microchip Technology Inc.

2355 West Chandler Blvd.

Chandler, Arizona, USA

Microchip Facebook
Microchip LinkedIn
Microchip Twitter
Microchip Instagram
Microchip Weibo

© Copyright 1998-2024 Microchip Technology Inc. All rights reserved. Shanghai ICP Recordal No.09049794

Terms Of Use
Privacy Notice
Legal
Your Privacy Choices California Consumer Privacy Act (CCPA) Opt-Out Icon