How often do you have to read the same 3GB file?
If the answer is "many times", there may be a benefit in saving to another file.
How much of the 3GB file do you throw away because it isn't necessary for your needs? For example, only 2 or 3 fields from a CSV file containing dozens of fields.
If the answer is "lots", there may be a benefit in saving to another file.
What variable types are in your struct?
If it's just
int, double, char (and arrays of those things), writing to a file can be pretty simple.
But if you've got pointers, and C++ objects like
std::string, things get more interesting.
How often might you change struct to incorporate additional fields, or remove old fields?
Any changes would invalidate (or at least make it harder) to handle pre-existing saved files.
> to store this data as a vector<struct> and have the program use that file?
Serialisation is a minefield.
https://isocpp.org/wiki/faq/serialization
Whilst it's always possible to do it, the benefit might be overshadowed by the complexity of doing it.