YES

Proof:
This system is quasi-decreasing.
By \cite{O02}, p. 214, Proposition 7.2.50.
This system is of type 3 or smaller.
This system is deterministic.
System R transformed to U(R).
Call external tool:
ttt2 - trs 30
Input:
  ?2(s(y), x, y) -> x
  ?1(y, x, y) -> ?2(g(g(x)), x, y)
  f(x, y) -> ?1(g(x), x, y)
  ?4(x, x, y) -> y
  ?3(s(x), x, y) -> ?4(g(g(y)), x, y)
  f(x, y) -> ?3(g(y), x, y)

 DP Processor:
  DPs:
   ?1#(y,x,y) -> ?2#(g(g(x)),x,y)
   f#(x,y) -> ?1#(g(x),x,y)
   ?3#(s(x),x,y) -> ?4#(g(g(y)),x,y)
   f#(x,y) -> ?3#(g(y),x,y)
  TRS:
   ?2(s(y),x,y) -> x
   ?1(y,x,y) -> ?2(g(g(x)),x,y)
   f(x,y) -> ?1(g(x),x,y)
   ?4(x,x,y) -> y
   ?3(s(x),x,y) -> ?4(g(g(y)),x,y)
   f(x,y) -> ?3(g(y),x,y)
  TDG Processor:
   DPs:
    ?1#(y,x,y) -> ?2#(g(g(x)),x,y)
    f#(x,y) -> ?1#(g(x),x,y)
    ?3#(s(x),x,y) -> ?4#(g(g(y)),x,y)
    f#(x,y) -> ?3#(g(y),x,y)
   TRS:
    ?2(s(y),x,y) -> x
    ?1(y,x,y) -> ?2(g(g(x)),x,y)
    f(x,y) -> ?1(g(x),x,y)
    ?4(x,x,y) -> y
    ?3(s(x),x,y) -> ?4(g(g(y)),x,y)
    f(x,y) -> ?3(g(y),x,y)
   graph:
    f#(x,y) -> ?3#(g(y),x,y) -> ?3#(s(x),x,y) -> ?4#(g(g(y)),x,y)
    f#(x,y) -> ?1#(g(x),x,y) -> ?1#(y,x,y) -> ?2#(g(g(x)),x,y)
   SCC Processor:
    #sccs: 0
    #rules: 0
    #arcs: 2/16