Skip to content

Conversation

@likivisw
Copy link
Contributor

v0.5.1 - Two-Stage Parsing System

Two-Stage Parsing Approach

  1. Alpha Parser (α) - Always runs first; resilient parser using heuristics for incomplete dependencies
  2. Beta Parser (β) - Runs only if no fatal/semantic/syntax errors; requires complete semantic resolution

Parsing Strategy

  • Alpha runs on both versions first
  • If fatal errors occur: Reports Alpha results only
  • If no errors: Proceeds to Beta, reports combined Alpha + Beta results

Dependency Resolution

Non-recursive upward traversal from current directory to project root (does not search subdirectories).

Alpha Parser (α)

Strengths: Works with missing dependencies, valid syntax required, applies heuristics for unresolved symbols

Detects:

  • Struct/union/enum: member changes, qualifier changes, tag renames
  • Functions: signature changes, parameter/return qualifiers, storage/linkage (with heuristics for unresolved types)
  • Variables/fields: qualifiers, storage, pointer indirection, array dimensions (with heuristics for unresolved types)

Limitations: No function overloading, typedefs, forward declarations, anonymous types, preprocessor directives, C++ OOP features

Beta Parser (β)

Strengths: Complete semantic resolution, handles arbitrary type complexity

Detects: Everything Alpha detects, plus:

  • Forward declarations (functions, structs, unions, enums)
  • Typedefs with semantic-aware comparison
  • Function overloading
  • Anonymous/nested types
  • Flexible array members
  • Complex type compositions (unlimited nesting)

Limitations: Same as Alpha for implementation details, preprocessor directives, ABI changes, C++ features

Quick Comparison

Feature Alpha (α) Beta (β)
Dependencies Optional Required
Forward Declarations
Typedefs
Function Overloading
Anonymous Types
Type Semantics Full (when resolved) Full (always)

New armor open source release v0.5.1

Signed-off-by: likith viswanath <likivisw@qti.qualcomm.com>
Updated action.yaml for armor release v0.5.1

Signed-off-by: likith viswanath <likivisw@qti.qualcomm.com>
@ayukum-hyd ayukum-hyd merged commit 8d3dcb8 into qualcomm:main Dec 10, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants