Rockbox

Tasklist

FS#12165 - Speed up genlang with a generated regex

Attached to Project: Rockbox
Opened by Torne Wuff (torne) - Wednesday, 22 June 2011, 22:06 GMT
Last edited by Thomas Martitz (kugel.) - Thursday, 08 September 2011, 14:44 GMT
Task Type Patches
Category Build environment
Status Closed
Assigned To No-one
Operating System All players
Severity Low
Priority Normal
Reported Version Daily build (which?)
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

With this change generating all languages takes only two-thirds the
time. It changes the acceptable syntax for target wildcards in language
files, however: instead of a comma-separated list of glob-style
wildcards it requires that it be a comma-separated list of prefix
matches, i.e. the * can only appear at the end of each wildcard, and ?
cannot be used. This does not require any changes to existing language
files as they are all already in this form.
This task depends upon

Closed by  Thomas Martitz (kugel.)
Thursday, 08 September 2011, 14:44 GMT
Reason for closing:  Accepted
Additional comments about closing:  r30481
Comment by Thomas Martitz (kugel.) - Wednesday, 22 June 2011, 23:36 GMT
Another problem I spotted with genlang which leads to quite a speedup if fixed.

$BUILD/apps/lang/english.list is some cache file for the english strings. readenglish() is this cache file if it's newer than english.lang. The problem is the cache file is never updated after initial creation, so the fast path in readenglish() is only taken until english.lang is modified. I attach a patch to fix that, resulting in quite a speed up since the the fast path in readenglish() is taken.

Perhaps english.list should be generated via a make rule instead.
Comment by Thomas Martitz (kugel.) - Wednesday, 22 June 2011, 23:42 GMT Comment by Jonas Häggqvist (rasher) - Wednesday, 27 July 2011, 23:16 GMT
I'll add my +1 to both of these.

Loading...