code: public final boolean compareAndSetForkJoinTaskTag(short e, short tag) {
          for (int s;;) {
              if ((short)(s = status) != e)
                  return false;
              if (U.compareAndSwapInt(this, STATUS, s,
                                      (s & ~SMASK) | (tag & SMASK)))
                  return true;
          }
      }
docs: Atomically conditionally sets the tag value for this task.
  Among other applications, tags can be used as visit markers
  in tasks operating on graphs, as in methods that check: {@code
  if (task.compareAndSetForkJoinTaskTag((short)0, (short)1))}
  before processing, otherwise exiting because the node has
  already been visited.
  
  @param e the expected tag value
  @param tag the new tag value
  @return true if successful; i.e., the current value was
  equal to e and is now tag.
  @since 1.8