This phase II trial studies how well treatment that is directed by genetic testing works in patients with solid tumors or lymphomas that have progressed following at least one line of standard treatment or for which no agreed upon treatment approach exists. Genetic tests look at the unique genetic material (genes) of patients' tumor cells. Patients with genetic abnormalities (such as mutations, amplifications, or translocations) may benefit more from treatment which targets their tumor's particular genetic abnormality. Identifying these genetic abnormalities first may help doctors plan better treatment for patients with solid tumors or lymphomas.