Just realized you're in Shanghai. Perfect example of tracking foreigners... they were manually doing it. Immigration control...they want to know the first place you're staying at. Then you get to the hotel. There they take a copy of your passport and report it to the local police. And every time you change addresses, the process repeats itself. Technically if you stay at a person's residence, they're supposed to let the local police know as well (most don't know to do this, but I have seen it get someone in trouble).
(And no, not SerpentZA or Laowhy86 ... other people)
It's not perfect, but with the geopolitical nature of things, expect them to become more stringent.