Commit Graph

6 Commits (a63e6f9dfd75f89841817a0185d606da52c7a4a6)

Author SHA1 Message Date
Lioncash a63e6f9dfd loader: Make the Load() function take a process as a regular reference, not a SharedPtr
A process should never require being reference counted in this
situation. If the handle to a process is freed before this function is
called, it's definitely a bug with our lifetime management, so we can
put the requirement in place for the API that the process must be a
valid instance.
7 years ago
Lioncash 45195a51a7 nax: Avoid re-parsing NAX data with GetFileType()
An instance of the NAX apploader already has an existing NAX instance in
memory. Calling directly into IdentifyType() directly would re-parse the
whole file again into yet another NAX instance, only to toss it away
again.

This gets rid of unnecessary/redundant file parsing and allocations.
7 years ago
Lioncash c8c4105659 nax: Avoid unnecessary calls to AsNCA() in IdentifyType()
AsNCA() allocates an NCA instance every time it's called. In the current
manner it's used, it's quite inefficient as it's making a redundant
allocation.

We can just amend the order of the conditionals to make it easier to
just call it once.
7 years ago
Zach Hilman 6314a799aa file_sys/crypto: Fix missing/unnecessary includes 7 years ago
Zach Hilman a7e8d10969 file_sys: Cut down on includes and copies 7 years ago
Zach Hilman 2164702cf7 nax: Add AppLoader_NAX and update loader to support it 7 years ago