This is partly a computer science question. Your if-statement is an instruction to a computer to perform y when condition x is true. Computer programs run very quickly, but they run in time as distinct events, causally related to one another.
Computer scientists though, when they analyze programs, do not treat them as causal structures made up of events but as logical structures made up of propositions. Your if-statement, in this context, becomes a statement not of what happens but of what must be true.
Computer scientists use this kind of analysis to prove that a program does what it is supposed to do. This proof is a mathematical or logical proof. It relies not on causal necessity but on logical necessity. Propositions are not in time in the same way that events are in time. For example a syllogism, if it is ever valid, is always valid. Its validity is not momentary or ephemeral the way causes are.
You ask "is this in time?" The answer is--it depends whether you are treating the statement as an instruction that is performed or as a logical proposition. If it is a performed instruction, it is in time, but if it is a logical proposition, then it is not causal.
I suppose a third way of treating the statement is as a law--whenever x happens, do y. Laws are the principles that govern causes. Are laws in time? I would say that they are also in time. In the case of a program, the law exists only while the computer is running the program, that is, at a definable time.
I do not think you have found an example of causality that occurs without time, and I cannot easily think of one myself. The only thing that suggests itself to me is the sequence of decisions that occur in the mind of an eternal being (where eternity is conceived of as somehow outside of time). Each decision depends causally on previous decisions without being logically necessitated by them and without happening in time. This is an example of what you are looking for, but not one whose existence we can easily verify.