Skip to content

Fold 2 calls to kpsewhich; avoid regexp in tightest loop#2514

Merged
brucemiller merged 1 commit intomasterfrom
kpsewhich
Feb 10, 2025
Merged

Fold 2 calls to kpsewhich; avoid regexp in tightest loop#2514
brucemiller merged 1 commit intomasterfrom
kpsewhich

Conversation

@brucemiller
Copy link
Copy Markdown
Owner

Small optimization to build_kpse_cache; seemingly worthwhile since it's invoked on every run.

@brucemiller brucemiller requested a review from dginev February 10, 2025 17:23
Copy link
Copy Markdown
Collaborator

@dginev dginev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is substr noticably faster than the regex capture? Curious - by how much?

Looks good to merge.

@brucemiller
Copy link
Copy Markdown
Owner Author

Maybe by a half for simple cases that easily map to substr; more for 1st char, less for last.

@brucemiller brucemiller merged commit 99aa96e into master Feb 10, 2025
26 checks passed
@brucemiller brucemiller deleted the kpsewhich branch February 10, 2025 18:35
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