For a finite input, there is no formal regular expression that will not halt.
Any formal regular expression can be translated into a Deterministic Finite Automata. A DFA reads the input one character at a time, and, at the end of the input, you are either in an accepting state or in a non-accepting state. If the state is accepting, then the input matches the regular expression. Otherwise, it doesn't.
Now, most "regular expression" libraries support things which are not regular expressions, such as back references. As long as you keep away from those features, and have a finite input, you are guaranteed a halt. If you don't... depending on exactly what you are using, you might well not be guaranteed a halt. Perl allows arbitrary code to be inserted, for instance, and arbitrary, turing-machine equivalent code is not guaranteed to halt.
Now, if the input is infinite, then trivial regular expressions can be found which will never halt. For example, ".*
".
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…