binaryninja-api icon indicating copy to clipboard operation
binaryninja-api copied to clipboard

Change function/field type textbox performance with large type database

Open mishka-freddy opened this issue 9 months ago • 5 comments

What is the feature you'd like to have? I have huge database with ~1.5kk types. So, when I want to change some function or field type, appears text box where I can do it. But due to type validness check, it makes me hard to write anything by hand, because it stuck for 4+ seconds each time when I type some chars. Maybe there's way to disable type check until I press Change button?

mishka-freddy avatar May 18 '25 11:05 mishka-freddy

Agreed. We should either dramatically improve performance or over some threshold only update the check based on some less frequent timer (preferably both)

psifertex avatar May 18 '25 15:05 psifertex

Ho many types do you have? Any chance you can share your database? 1.5k types isn't a whole lot.

plafosse avatar Jun 10 '25 14:06 plafosse

~1.5kk (1 500 000) types, database size 40 GB, and it takes ~80 GB RAM memory when loaded. It's kinda private, so I cannot share it public, but Binary Ninja portal able load only up to 1GB.

mishka-freddy avatar Jun 11 '25 07:06 mishka-freddy

~1.5kk (1 500 000) types, database size 40 GB, and it takes ~80 GB RAM memory when loaded. It's kinda private, so I cannot share it public, but Binary Ninja portal able load only up to 1GB.

You can email it to binaryninja at vector35.com as well

xusheng6 avatar Jun 11 '25 08:06 xusheng6

~1.5kk (1 500 000) types, database size 40 GB, and it takes ~80 GB RAM memory when loaded. It's kinda private, so I cannot share it public, but Binary Ninja portal able load only up to 1GB.

You can email it to binaryninja at vector35.com as well

Thank you, sent

mishka-freddy avatar Jun 11 '25 08:06 mishka-freddy

This was received last week, just forgot to put a note in here. V35 employees can search for gradually smuggling primate progeny to find the file (which is, as promised, quite large!).

fuzyll avatar Jun 20 '25 19:06 fuzyll

Any updates on this task? Because for me kinda hard to use BN on large db due to this.

michael-zendaro avatar Oct 10 '25 10:10 michael-zendaro

We need to re-think the change type code but in the short term please disable this setting and see if that helps: "ui.types.checkParse"

plafosse avatar Oct 13 '25 13:10 plafosse

Fixed in 5.2.8402

plafosse avatar Oct 19 '25 17:10 plafosse

@mishka-freddy The binary gradually smuggling primate progeny was a treasure trove of performance edge cases. Using >= 5.2.8402 the BNDB opens and analyzes much much faster. I would recommend opening the bndb then "Save Analysis Database With Options" check purge snapshots and purge undo actions. This will result in a much smaller BNDB and subsequent opens of that file will be faster.

plafosse avatar Oct 19 '25 18:10 plafosse

@plafosse I'm glad this binary helped you. And thank you so much for fixing it and performance improvement, I already feel that it works much faster. And rly, I even couldn't assume that undo actions take so much space, thank one more time.

mishka-freddy avatar Oct 19 '25 19:10 mishka-freddy