sifive / wake

The SiFive wake build tool
Other
86 stars 28 forks source link

stdlib: Add list functions #1648

Closed V-FEXrt closed 2 months ago

V-FEXrt commented 2 months ago

I'm working on fixes to breakages in v44.0.0 and it felt better to split things up instead of trying to make one larger disparate PR.

This PR adds list intersect and subset both of which are needed for the upcoming fixes. Care was taken to ensure they didn't run N^2. They roughly run in 2*nlogn + n where n = max(lhs.len, rhs.len) though I am assuming sortBy is nlogn which I've not verified