I searched for this answer and came up with no results. Apologies if somebody answered this yesterday....
In Lightroom, the "Export Original" function outputs a copy of the original file, with metadata applied as per the setting in the metadata section of the export dialog.
Assuming a JPEG file here, I need to confirm that the metadata is embedded losslessly. I would think so. I would darn well hope so. But before I tell a client to do this, I would feel better if somebody who knows for sure reassured me.
(Background is that I don't want the LR Hierarchical Subject field written. Using the Export function allows you to specify just that behavior. Otherwise, I could just tell the client to "Save Metadata to File" and grab the original file from the file system.)
I was hoping some engineer would say, "I wrote that and yes, that's the way it works." But it appears we've arrived at that conclusion under our own power 🙂
For what it's worth, I did the same thing you did, but in ImageMagick. I used their compare command, which looks for non-matching pixels, and repeated with their signature command, which makes a hash, a la MD5, out of just the image data. (A very cool thing. I didn't know they had that.) Both showed no differences. So I guess I can tell my client that we're good.
I have had poor experiences in the past using the difference layer technique, by the way. I have had it fail to detect JPEG recompression, which is exactly the issue here. The ImageMagick docs make a big deal of how their output will freak if it encounters recompression. So, pending anybody reporting otherwise, I suppose we can trust that this Lightroom function works as expected.
"I have had poor experiences in the past using the difference layer technique, by the way. I have had it fail to detect JPEG recompression, which is exactly the issue here."
Open the two files in PS as layers, set one to Difference Blending, add a Levels Adjustment Layer, and set the White slider below the Levels Histogram all the way to the left (2 level). Here's an example using TIFF 8bit sRGB and JPEG 80 Quality sRGB export files. Even an image with only one pixel different is visble.