Aircraft: B777
Phase of flight: Cruise
Anomaly: Aircraft Equipment Problem Less Severe; Deviation - Speed All Types; Deviation / Discrepancy - Procedural Published Material / Policy; Inflight Event / Encounter Fuel Issue

I had just leveled the aircraft at FL380; approx. 30 miles from West of [waypoint] (eastbound) with the autopilot engaged. An FAA Maintenance Inspector had just left the cockpit. Crew meals were waiting at the door to be delivered. I donned my O2 mask as the Captain left her seat to open the cockpit door when suddenly a subtle but noticeable thud was felt in my seat bottom and toes resting lightly on the rudder pedals. Center called us to terminate radar services and switch us to enroute (HF) communication but I advised them that we wanted to remain in VHF contact as long as possible since I sensed an engine problem possibly developing.They gave us an alternate frequency but said it was only good for another 50 miles. At this time; I heard a light whistling sound behind the instrument panel that I hadn't noticed before. Looking at the engines; I observed a slightly lower N1 on the left engine. The Captain quickly returned to her seat and we discussed the indications. While a little hazy on the exact details and sequence of events; I seem to recall we had another brief; slightly larger thud as the Captain reduced power on the left engine to stabilize the N1 at about the 6 o'clock position. The compressor stall checklist was then run by the Captain and I quickly dropped my mask beside me.Simultaneously; an attempt was being made by the FAA Maintenance Inspector and a deadheading First Officer (FO) in the cabin to gain cockpit access using the emergency cockpit access code which seemed confusing/distracting as we were dealing with the situation. After a failed first attempt; they eventually were admitted. The FAA inspector took the #2 observer's seat while the deadheading FO sat in the number 1 Observer's seat and began to work with the Captain running the Severe Engine Damage (shutdown) checklist when engine temperature began to spike after trying to initially recover the engine by slowly pushing up the throttle per the Compressor Stall checklist. The throttle was slowly advanced from the 6 o'clock position but when almost back to the normal cruise 10 o'clock position; a much larger 'thud' occurred; the N1 collapsed; and EGT began to rise rapidly (up to 800 plus deg.?).Knowing that an engine shutdown was imminent; I took the initiative by requesting a descent to FL200 after viewing the 'Eng Out'; prompt on the FMC VNAV page. While a diversion airport had not yet been decided on; it seemed reasonable to me that we at least get turned around and heading in the right (westbound) direction. A descent clearance to FL200 was granted and a 180 degree turn was granted and I commenced a slow right turn and descent before the airspeed decayed too much (10-15 kts at that point). ATC asked for [an update] and I told them to standby while I assessed how high; how far (to ZZZ) and how much fuel we would have after dumping. Later; though not specifically instructed by the Captain due to workload concerns; I advised ATC that we would likely land on [the longest runway] in ZZZ and to have the fire trucks standing by near the high speed intersection Y.I descended in VS mode initially selecting 2;000 fpm to recapture the decayed speed (15 kts) while bugging up to about 300 kts. A 30 mile ring was drawn around ZZZ as I also noted the diversion options near us and mentally calculating about how far they were; checklists still remaining to be run; their runway lengths and my relative familiarity/recency of experience in each. Once stabilized in descent at about 12-1500 fpm at 300 kts and minimal thrust on right engine; I redirected my attention to the discussion between the Captain and newly designated IRO. Flight attendants reported a slight odor in the cabin. [We] were heavily engrossed discussing with Dispatch and [maintenance] what had happened and that we were diverting. By observing the current aircraft weight; and after advising ATC of their requested information; I then also took the initiative to coordinate approval for fuel jettison and it was approved. When the discussion eventually evolved into landing weight; diversion airport; etc.; I advised the Captain & IRO that we had been approved to dump fuel. Initially; the Fuel Auto Jettison checklist was run but later discarded in favor of the correct (unannunciated) Fuel Jettison checklist. As we began to dump fuel; we received an ATC clearance to descend to 10;000 feet and we continued to dump down to Maximum Landing Weight (MLW).After fuel jettison was complete we found ourselves with approx. 4;000 pounds imbalance between main tanks. We decided to run the fuel imbalance checklist to slowly bring them closer to equality. We opted to not finish this checklist before landing since we were already on a downwind abeam the field and were briefing running other checklists and coordinating with the flight attendants and passengers. The approach and landing was uneventful and we turned off onto the taxiway just beyond Y and set the brake as 4 fire trucks converged and advised us on ground frequency that there was no fire. After telling the passengers this news and to remain seated; we eventually were towed to the gate and the passengers disembarked. We inspected the affected engine with the FAA maintenance inspector and observed the destroyed turbine sections. The Captain had an impromptu debrief with the entire crew present with the FAA to discuss impressions/reactions; etc. In our haste to vacate the aircraft since maintenance wanted to tow the aircraft off the gate; we neglected to send in an FRM on the incident. I was deadheading to work. I was in the passenger cabin. As the flight attendants started their meal and beverage service; I heard a pop and started to feel vibration; although very slight. I got up from my seat and I called the captain to offer my services (I had introduced myself to her during boarding; giving her my seat number and offer to help if anything came up). Captain asked me to come to the cockpit and assist. Upon arriving at the cockpit; the first officer; who was flying the aircraft; had already started a turn back to ZZZ and also commenced a descent. The captain asked me to contact dispatch; which I did over the SATCOM. I advised the dispatcher of the nature of our [situation] and our intentions. After that; I assisted the captain with various checklist - the continuation and conclusion of the engine fire/severe damage checklist; and the fuel jettison checklist. After the conclusion of those items; we got a fuel imbalance EICAS message and I worked with the captain to accomplish that check.During the descent; we did a quick review and critique to make sure no items were missed. By this time we were over our [destination] and concentrated our efforts on landing. A normal ILS was flown to landing. I made the announcement for all passengers to remain seated (as previously briefed by the captain). The captain elected to have the crash/fire/rescue vehicles meet the aircraft. They checked out the left engine; found no fire or fluids leaking; and awaited our intentions. The captain elected to shut down the aircraft and have ZZZ station personnel tow the aircraft to [the] gate. A B-777 flight crew lost an engine while enroute. They ran appropriate checklists; dumped fuel; and returned to their departure airport and landed.