Skip to content

Improved Special Files Support#206

Merged
FinnWilkinson merged 18 commits intomainfrom
Special-Files-PR
Dec 17, 2021
Merged

Improved Special Files Support#206
FinnWilkinson merged 18 commits intomainfrom
Special-Files-PR

Conversation

@FinnWilkinson
Copy link
Copy Markdown
Contributor

This pull request properly implements the use of Special System Files required by OpenMP. Using data from new fields of the Config files, a replica directory tree is created at runtime that includes commonly accessed special files.

The special files created are accurate replicas of their counterparts found on the appropriate Isambard node for the model.
Also included in the PR is a custom getdents64 implementation. This was required when running OpenMP based binaries through SimEng on Mac-based, and some Linux-based, systems that do not support the syscall natively (and so the call cannot be passed to the host).

Additionally, the heap and stack size is now defined in the config files; allowing more memory-hungry binaries to be run, as well as allowing for a reduced image size when testing resulting in a significant test-suite speedup.

@FinnWilkinson FinnWilkinson added bug Something isn't working enhancement New feature or request performance Performance optimisation labels Dec 16, 2021
@FinnWilkinson FinnWilkinson linked an issue Dec 16, 2021 that may be closed by this pull request
FinnWilkinson and others added 17 commits December 17, 2021 11:21
…ModelConfig code and Main to support the new fields in the YAML config file, validate the values in the config file, and initiate special files dir generation if indicated.
…e if requested in YAML config, adds cpuinfo, online files, and creates sub folder for each cpu core. Added special files directory to git ignore.
… and readdir syscalls. This is needed as not all operating systems use getdents64 and so it can't always be passed to the host. Needs validating on system that supports getdents64 natively as test value needed changing.
… MacOS. Currently not working but changes needed pushing so can be cloned onto another machine.
… directory subject to change between config files).

Also altered openat flags for dirfd syscalls to O_RDONLY to be more robust across different host devices.
 - Wouldn't open one of the special files directorys as flag permissions were wrong. Now set flags to O_RDONLY and O_CLOEXEC only as cannot write to special files or special file directories.
…er. Getdents64 custom implementation not functioning correctly.
…1GiB from 10MiB as multiple benchmarks were running out of space
…image size when testing, reducing the runtime of tests
…ons, as well as default stack and heap sizes.
…er support. Filesystem header used previously replaces with mkdir and rm calls that are passed to the console.
@FinnWilkinson FinnWilkinson merged commit 9790b4a into main Dec 17, 2021
@jj16791 jj16791 deleted the Special-Files-PR branch December 17, 2021 16:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working enhancement New feature or request performance Performance optimisation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Compilation fails on '::getdents64'

2 participants