Well, as a software "engineer" there's a huge can of worms on this particular topic. Steve McConnell wrote an entire book with lots of related discussion "Professional Software Development: <plus bunch of subtitle>".Engineering is a regulated profession. Strictly speaking Elon is not an engineer, since he does not have an engineering degree and does not have professional credentials. That's regardless of whether he is doing work that could be considered engineering.
I'm a huge buff on software history/culture /practice and could talk at length on it . The short end is you're right, software isn't regulated, but I'm not sure I'd concede that it takes regulation to make something "engineering". Engineers existed before regulations. I've got a BSCS and a Masters in "Software Engineering" (the program was "Oregon Master of Software Engineering), so I feel fairly comfortable saying I'm a software engineer, though in the software world developer/engineer/programmer are all applicable and used somewhat interchangeably.