--- a/src/hotspot/share/memory/virtualspace.hpp Wed Nov 29 10:30:51 2017 -0800
+++ b/src/hotspot/share/memory/virtualspace.hpp Wed Nov 29 17:03:10 2017 -0800
@@ -37,6 +37,7 @@
size_t _noaccess_prefix;
size_t _alignment;
bool _special;
+ int _fd_for_heap;
private:
bool _executable;
@@ -115,7 +116,9 @@
void establish_noaccess_prefix();
public:
// Constructor. Tries to find a heap that is good for compressed oops.
- ReservedHeapSpace(size_t size, size_t forced_base_alignment, bool large);
+ // heap_allocation_directory is the path to the backing memory for Java heap. When set, Java heap will be allocated
+ // on the device which is managed by the file system where the directory resides.
+ ReservedHeapSpace(size_t size, size_t forced_base_alignment, bool large, const char* heap_allocation_directory = NULL);
// Returns the base to be used for compression, i.e. so that null can be
// encoded safely and implicit null checks can work.
char *compressed_oop_base() { return _base - _noaccess_prefix; }