The IR2112 uses a charge pump (C2 and D1) to increase Gate drive voltage. For this to work properly you must apply PWM to HIN, which keeps C2 charged up.
Each time the FET turns on it pulls the load voltage high. Since C2 is already charged up to nearly 15V, and D1 stops it from discharging into the 15V supply, the boost voltage at VB will go up to almost 15V above the FET's Drain voltage (ie. to about 115V). The driver then switches between this boost voltage and VS, providing close to 15V Gate drive to the FET even though it is way above VC. C2 will loose some charge through the gate drive circuit, but when the FET is turned off again (during PWM off time) it is recharged through the load (R4).
If you hold HIN high continuously then C2 will continue to discharge through R1 and R2. Eventually the drive voltage will drop below the FETs threshold voltage and it will start to turn off, then boost voltage will drop and you will be left with only the 15V from VS. The load voltage will drop even lower because the IRF840 needs about 6V to turn on.
Another potential problem with your circuit is that C2 is being discharged through R1 and R2 almost as fast as it is being charged through R4. Over many PWM cycles the average voltage on C2 will drop, reducing Gate drive. At 50% PWM or above the drive voltage might drop below the FETs threshold voltage, causing it to turn off too soon. This can be fixed by either increasing the value of R2 or reducing the value of R4.
Since you're just switching a magnet, you don't need high speed, or high gate current. However, since your MCU operates on 3.3 volts, you do need some sort of driver to guarantee that your MOSFET gets turned on strongly, and 3.3 volts on an output just won't do that.
For a simple case like this, all you need is a transistor and a few resistors, and
simulate this circuit – Schematic created using CircuitLab
this will do, as long as you don't mind the fact that the signal is inverted. That is, a high output at the MCU will turn the relay off, not on. Note a few things. R2 and R3, when the transistor is off, set the gate drive at 12 volts. Without the combination, using only R2 would apply a maximum of 24 volts to the gate, and this exceeds the maximum specification. Also, D1 is called a flyback diode, and you should always use one when switching anything with a coil. If you don't, when you turn off the relay you'll get a big voltage spike across it, and you may well kill your transistor. Worse, sometimes it will take multiple operations to kill the transistor, so you think you've got a working circuit, but you can't understand why it's unreliable. The diode should be rated for whatever current the relay coil draws, and have a higher voltage rating than the power supply.
Best Answer
There is nothing wrong with driving a FET like this if there is no need to PWM.
What I would add is
NOTE: you might want something bigger than just a Zener on the gate. TVS maybe. its dependent where exactly the FET sits with regards to indirect lightning. The DO160 is not very forgiving.