Can the luminosity masks of a single file be different in two computers? I explain; trying to understand this type of masks and the selections associated to them, I created a document with a black and white gradient fill, RGB color mode, 8 bits and 100% opacity over its entire surface. That document opened in PHOTOSHOP CC V. 19. 1.1, when loading the selection associated to the RGB channel, is different if I execute it in my iMac 27 or when I execute it in my MacBooK Pro, also with PS CC V: 19.1.1 and the same operating system macOS High Sierra V: 10.13.3.
A luminosity mask should use the L channel in Lab, which is device independent and universal.
But I don't know precisely where in the chain the marching ants' 50% boundary is calculated. If it's done in the document's original color space, the color profile will determine where 50% is. The tone response curve is different between, say, Adobe RGB (gamma 2.2) and ProPhoto (gamma 1.8).
Either way, it's of no consequence. The mask is the same. It's just the 50% dotted line which in any case is just for display purposes. This might even be done in the GPU with monitor RGB data.