[Solved] [SCRIPT] PurgeWrangler: AMD + NVIDIA eGPUs for all Thunderbolt Macs
@jeroen-van-keulen Please see the main post's Step 2, which now uses a version-agnostic terminal command. This means you won't have to update the installer every time per version. It will simply fetch and download the latest version automatically.
So first I want to say thanks! These scripts are fantastic. I have a 2015 MacBook Pro, and I've been looking forward to the prospect of have an eGPU. Then I heard Apple dropped support for everything without Thunderbolt 3, which prompted me to find this website. I haven't purchased any hardware yet (because the crypto-mining buttholes screwed up the GPU market), but I was curious how the script worked.
After browsing the purge-wrangle.sh script, I found out it's literally just a string replacement. <Moderated //@mac_editor>. So at this point I understood WHAT worked, but I didn't know WHY it worked.
So I downloaded the Hopper Disassembler, as it is able to show cool things like control flow graphs and convert assembly into pseudocode, which looks like a strange mix of assembly and C.
BTW, I don't have much experience reverse engineering and modifying executable code, but I do sometimes browse assembly generated from my C++ compiler.
Here is the pseudocode:
Here is the assembly:
And now we see why only Thunderbolt3 works. <Moderated //@mac_editor>. The purge-wrangler.sh script modifies the kernel extension to only check for the Thunderbolt version that is on your current system.
So basically, I wouldn't say Apple is actively blocking Thunderbolt 1/2. They are just not supporting it. If we had the source code, we could easily change this to support TB2 and TB1. Oh well. Poop.
@duhlong Posting Apple code (especially disassembled) and discussing the details in public is not recommended/permitted - although we don't have such rules at the moment. I have read your post and you're exactly correct in how purge-wrangler works, but in this case, I feel I cannot approve your post here. Sincerest apologies.
Also, about "actively blocking" vs. "not supported" - I felt the former was more accurate because TB1 & 2 were never supported to begin with. Now they are blocked, in a rudimentary sense.
Edit: Have moderated your post and approved. Good work looking into this. I used Hopper as well.
@mac_editor Ah, OK. Apologies. I just thought it would be interesting. I didn't consider any legal issues surrounding posting Apple's assembly. That thought did not cross my mind. Though I see you took out a verbal description as well. Also unsure of the legalities of verbally describing such details.
@duhlong Appreciate your understanding! Thank you, and welcome to egpu.io.
Thanks Guys! Works now "almost" like charm. The 580 is detected and also in use.
Why only "almost"? I have huge problems with sleep/wakeup processes. It seems that my macbook goes not into sleepmode properly and is rebooting.
Anyone also with the same issues and maybe a solution?
@thefurious Script also has a hibernation disable option. Please try that.
Its fixed and updated. I cant respond to our private message. Somehow this webforum is breaking down on me. I cant quote people anymore, I cant upload anything and my earlier uploads I cant see. And now the latest responses are hovering over the send button in private messages mode, but only in our conversation...
MBP11,4, i7-4980HQ, 256gb SSD, 16gbRAM Cathalina (Sonnet Breakaway box 350 + Gigabyte Radeon RX 580 Gaming 8GB)
MacBook7,1 A1342, P8600 120gb SSD 4gbRAM. Mojave (Hiking/Camping)
iMac7,1 A1224, T9500 CPU upgrade 120gb SSD 4gbRAM. HS
Mac mini3,1 P7350, 250gb SSD 8gbRAM. HS (server) iPhone10,3 64gb. iOS12 iPad5,3, 16gb. iOS12 iPod shuffle 2nd gen. 2gb
@jeroen-van-keulen Thanks for letting me know. Noticed that too. Messages is broken. Doesn't handle long lines well.