I am using this setup to convert a sine signal from the X component to a square wave signal using an op amp

And it works as expected

Next i made the amplitude of the signal increase over time like so:

when the output of X1 is not connected to the op amp the sine wave goes to about -1v to +1v peak to peak at the end of the simulation

but when connected, the output of the op amp is ok, but the signal voltage goes bellow -400v and over +400v peak to peak

it gets weirder when i make the amplitude of the sine wave increase over time to some limit and then decrease back to 0 over time
when X1 is not connected to the op amp, i get this signal from it

but when connected i get the following

Am i doing something wrong ? because i expect the output from the op amp to be similar to the third image.
QSpice build sep 13 2024

And it works as expected

Next i made the amplitude of the signal increase over time like so:

when the output of X1 is not connected to the op amp the sine wave goes to about -1v to +1v peak to peak at the end of the simulation

but when connected, the output of the op amp is ok, but the signal voltage goes bellow -400v and over +400v peak to peak

it gets weirder when i make the amplitude of the sine wave increase over time to some limit and then decrease back to 0 over time
when X1 is not connected to the op amp, i get this signal from it

but when connected i get the following

Am i doing something wrong ? because i expect the output from the op amp to be similar to the third image.
QSpice build sep 13 2024

