Skip to content

Conversation

jepler
Copy link
Contributor

@jepler jepler commented Aug 14, 2025

Summary

These files are only built on demand for developers, and it is a quick process.

Without this, a sequence like this would leave the developer with an outdated main.pp to inspect:

make build-standard/main.o  # Create dependency information
make build-standard/main.pp
touch input.h
make build-standard/main.pp # Rebuilds now, wouldn't have before

Testing

I locally used the .pp targets and they behaved as I stated above.

Trade-offs and Alternatives

Initially I wanted to use dependency analysis but this seems the better way based on discussion.

Copy link

codecov bot commented Aug 14, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.38%. Comparing base (744270a) to head (0e87ec3).
⚠️ Report is 63 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master   #17922   +/-   ##
=======================================
  Coverage   98.38%   98.38%           
=======================================
  Files         171      171           
  Lines       22295    22296    +1     
=======================================
+ Hits        21936    21937    +1     
  Misses        359      359           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link

Code size report:

   bare-arm:    +0 +0.000% 
minimal x86:    +0 +0.000% 
   unix x64:    +0 +0.000% standard
      stm32:    +0 +0.000% PYBV10
     mimxrt:    +0 +0.000% TEENSY40
        rp2:    +0 +0.000% RPI_PICO_W
       samd:    +0 +0.000% ADAFRUIT_ITSYBITSY_M4_EXPRESS
  qemu rv32:    +0 +0.000% VIRT_RV32

@jepler jepler force-pushed the preprocessor-dependency branch from a0cdb01 to 831ae98 Compare August 14, 2025 16:04
@dpgeorge dpgeorge added the py-core Relates to py/ directory in source label Aug 15, 2025
@dpgeorge
Copy link
Member

It might be better to just make the .pp targets .PHONY so that they're always re-made. They're quick enough, and the use case I'm aware of is for a developer who is explicitly invoking make for just that purpose.

Yes, that's probably a better and simpler solution. They are anyway only built when explicitly asked for, they are never build automatically.

@jepler jepler force-pushed the preprocessor-dependency branch from 831ae98 to 50c4089 Compare August 28, 2025 02:46
@jepler jepler changed the title mkrules: Apply object file dependencies to preprocessor targets. mkrules: Always rebuild preprocessor targets. Aug 28, 2025
These files are only built on demand for developers, and it is
a quick process.

Without this, a sequence like this would leave the developer
with an outdated `main.pp` to inspect:
```
make build-standard/main.pp
touch input.h
make build-standard/main.pp # Rebuilds now, wouldn't have before
```

Signed-off-by: Jeff Epler <jepler@gmail.com>
@jepler jepler force-pushed the preprocessor-dependency branch from 50c4089 to 0e87ec3 Compare August 28, 2025 12:41
@dpgeorge
Copy link
Member

Thanks for updating. Rebased and merged in b6cd577

@dpgeorge dpgeorge closed this Aug 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
py-core Relates to py/ directory in source
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants