This phase II trial studies how well PI3K/mTOR inhibitor LY3023414 works in treating patients with solid tumors, non-Hodgkin lymphoma, or histiocytic disorders with TSC or PI3K/MTOR mutations that have spread to other places in the body and have come back or do not respond to treatment. PI3K/mTOR inhibitor LY3023414 may stop the growth of cancer cells by blocking some of the enzymes needed for cell growth.